Class AbstractQueryRequestHandler
java.lang.Object
org.eclipse.rdf4j.http.server.repository.handler.AbstractQueryRequestHandler
- All Implemented Interfaces:
QueryRequestHandler
- Direct Known Subclasses:
DefaultQueryRequestHandler
A base implementation to handle an HTTP query request.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Object
evaluateQuery
(Query query, long limit, long offset, boolean distinct) protected long
getLimit
(javax.servlet.http.HttpServletRequest request) protected org.springframework.web.servlet.ModelAndView
getModelAndView
(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, boolean headersOnly, RepositoryConnection repositoryCon, org.springframework.web.servlet.View view, Object queryResult, FileFormatServiceRegistry<? extends FileFormat, ?> registry) protected long
getOffset
(javax.servlet.http.HttpServletRequest request) protected abstract Query
getQuery
(javax.servlet.http.HttpServletRequest request, RepositoryConnection repositoryCon, String queryString) protected abstract String
getQueryString
(javax.servlet.http.HttpServletRequest request, org.springframework.web.bind.annotation.RequestMethod requestMethod) protected abstract FileFormatServiceRegistry
<? extends FileFormat, ?> getResultWriterFor
(Query query) protected abstract org.springframework.web.servlet.View
getViewFor
(Query query) org.springframework.web.servlet.ModelAndView
handleQueryRequest
(javax.servlet.http.HttpServletRequest request, org.springframework.web.bind.annotation.RequestMethod requestMethod, javax.servlet.http.HttpServletResponse response) protected boolean
isDistinct
(javax.servlet.http.HttpServletRequest request)
-
Constructor Details
-
AbstractQueryRequestHandler
-
-
Method Details
-
handleQueryRequest
public org.springframework.web.servlet.ModelAndView handleQueryRequest(javax.servlet.http.HttpServletRequest request, org.springframework.web.bind.annotation.RequestMethod requestMethod, javax.servlet.http.HttpServletResponse response) throws HTTPException, IOException - Specified by:
handleQueryRequest
in interfaceQueryRequestHandler
- Throws:
HTTPException
IOException
-
evaluateQuery
protected abstract Object evaluateQuery(Query query, long limit, long offset, boolean distinct) throws ClientHTTPException - Throws:
ClientHTTPException
-
getViewFor
-
getResultWriterFor
protected abstract FileFormatServiceRegistry<? extends FileFormat,?> getResultWriterFor(Query query) -
getQueryString
protected abstract String getQueryString(javax.servlet.http.HttpServletRequest request, org.springframework.web.bind.annotation.RequestMethod requestMethod) throws HTTPException - Throws:
HTTPException
-
getQuery
protected abstract Query getQuery(javax.servlet.http.HttpServletRequest request, RepositoryConnection repositoryCon, String queryString) throws IOException, HTTPException - Throws:
IOException
HTTPException
-
getModelAndView
protected org.springframework.web.servlet.ModelAndView getModelAndView(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, boolean headersOnly, RepositoryConnection repositoryCon, org.springframework.web.servlet.View view, Object queryResult, FileFormatServiceRegistry<? extends FileFormat, ?> registry) throws ClientHTTPException- Throws:
ClientHTTPException
-
isDistinct
protected boolean isDistinct(javax.servlet.http.HttpServletRequest request) throws ClientHTTPException - Throws:
ClientHTTPException
-
getOffset
- Throws:
ClientHTTPException
-
getLimit
- Throws:
ClientHTTPException
-