Class BaseSparqlQueryHandler
Abstract Base class for Handlers which provide SPARQL Query endpoints
Namespace: VDS.RDF.Web
Assembly: dotNetRDF.Web.dll
Syntax
public abstract class BaseSparqlQueryHandler : IHttpHandler
Fields
| Improve this Doc View Source_config
Handler Configuration
Declaration
protected BaseQueryHandlerConfiguration _config
Field Value
Type | Description |
---|---|
BaseQueryHandlerConfiguration |
Properties
| Improve this Doc View SourceIsReusable
Returns that the Handler is reusable
Declaration
public bool IsReusable { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Methods
| Improve this Doc View SourceHandleErrors(HttpContext, String, String, Exception)
Handles errors in processing SPARQL Query Requests
Declaration
protected virtual void HandleErrors(HttpContext context, String title, String query, Exception ex)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context | Context of the HTTP Request |
String | title | Error title |
String | query | Sparql Query |
Exception | ex | Error |
HandleErrors(HttpContext, String, String, Exception, Int32)
Handles errors in processing SPARQL Query Requests
Declaration
protected virtual void HandleErrors(HttpContext context, String title, String query, Exception ex, int statusCode)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context | Context of the HTTP Request |
String | title | Error title |
String | query | Sparql Query |
Exception | ex | Error |
System.Int32 | statusCode | HTTP Status Code to return |
LoadConfig(HttpContext)
Loads the Handler Configuration
Declaration
protected abstract BaseQueryHandlerConfiguration LoadConfig(HttpContext context)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context | HTTP Context |
Returns
Type | Description |
---|---|
BaseQueryHandlerConfiguration |
ProcessQuery(SparqlQuery)
Processes a Query
Declaration
protected virtual Object ProcessQuery(SparqlQuery query)
Parameters
Type | Name | Description |
---|---|---|
SparqlQuery | query | Query |
Returns
Type | Description |
---|---|
Object |
Remarks
Implementations should override this method if their behaviour requires more than just invoking the configured Query processor
ProcessRequest(HttpContext)
Processes a SPARQL Query Request
Declaration
public void ProcessRequest(HttpContext context)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context | HTTP Context |
ProcessResults(HttpContext, Object)
Processes the Results and returns them to the Client in the HTTP Response
Declaration
protected virtual void ProcessResults(HttpContext context, Object result)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context | HTTP Context |
Object | result | Result Object |
Remarks
Implementations should override this if they do not want to use the default results processing behaviour provided by SendToClient(IHttpContext, Object)
ShowQueryForm(HttpContext)
Generates a Sparql Query Form
Declaration
protected virtual void ShowQueryForm(HttpContext context)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context |
UpdateConfig(HttpContext)
Updates the Handler Configuration
Declaration
protected virtual void UpdateConfig(HttpContext context)
Parameters
Type | Name | Description |
---|---|---|
HttpContext | context | HTTP Context |