Class PluginEndPoint
Represents a base type for plugin end points to be targeted by the PluginsHandler
public abstract class PluginEndPoint
- Inheritance
-
objectPluginEndPoint
- Derived
Properties
Accepts
public FlexibleContentType Accepts { get; protected set; }
Property Value
- FlexibleContentType
Name
Gets the name of the end point
public string Name { get; }
Property Value
PluginFeature
Gets the plugin the end point is associated with
[JsonIgnore]
public PluginFeature PluginFeature { get; }
Property Value
PluginInfo
Gets the plugin info of the plugin the end point is associated with
public PluginInfo PluginInfo { get; }
Property Value
Returns
Gets the mime type of the output this end point returns
public FlexibleContentType Returns { get; protected set; }
Property Value
- FlexibleContentType
Url
Gets the full URL of the end point
public string Url { get; }
Property Value
Methods
OnProcessedRequest(IRequest)
Invokes the ProcessedRequest event
protected virtual void OnProcessedRequest(IRequest request)
Parameters
requestIRequest
OnProcessingRequest(IRequest)
Invokes the ProcessingRequest event
protected virtual void OnProcessingRequest(IRequest request)
Parameters
requestIRequest
OnRequestException(Exception)
Invokes the RequestException event
protected virtual void OnRequestException(Exception e)
Parameters
eExceptionThe exception that occurred during the request
ProcessRequest(IRequest)
Called whenever the end point has to process a request
protected abstract Task<IResponse> ProcessRequest(IRequest request)
Parameters
requestIRequestThe HTTP context of the request
Returns
- Task<IResponse>
Events
ProcessedRequest
Occurs whenever a request was processed
public event EventHandler<EndpointRequestEventArgs>? ProcessedRequest
Event Type
ProcessingRequest
Occurs whenever a request is about to be processed
public event EventHandler<EndpointRequestEventArgs>? ProcessingRequest
Event Type
RequestException
Occurs whenever a request threw an Unhandled error
public event EventHandler<EndpointExceptionEventArgs>? RequestException