Class SparqlQueryAjaxController
- java.lang.Object
-
- javax.servlet.GenericServlet
-
- javax.servlet.http.HttpServlet
-
- edu.cornell.mannlib.vitro.webapp.controller.ajax.VitroAjaxController
-
- edu.cornell.mannlib.vitro.webapp.controller.ajax.SparqlQueryAjaxController
-
- All Implemented Interfaces:
Serializable,javax.servlet.Servlet,javax.servlet.ServletConfig
@WebServlet(name="ajaxSparqlQuery", urlPatterns="/ajax/sparqlQuery") public class SparqlQueryAjaxController extends VitroAjaxControllerHandle an AJAX request for a SPARQL query. On entry, the "query" parameter contains the query string. The result is delivered in JSON format.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringOPTION_MODEL_FULLstatic StringOPTION_MODEL_USER_ACCOUNTSstatic StringPARAMETER_MODELstatic StringPARAMETER_QUERYstatic StringRESPONSE_MIME_TYPE
-
Constructor Summary
Constructors Constructor Description SparqlQueryAjaxController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voiddoRequest(VitroRequest vreq, javax.servlet.http.HttpServletResponse response)Sub-classes must implement this method to handle both GET and POST requests.protected AuthorizationRequestrequiredActions(VitroRequest vreq)By default, a controller requires authorization for no actions.-
Methods inherited from class edu.cornell.mannlib.vitro.webapp.controller.ajax.VitroAjaxController
doError, doGet, doPost, writeTemplate
-
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
-
-
-
-
Field Detail
-
PARAMETER_QUERY
public static final String PARAMETER_QUERY
- See Also:
- Constant Field Values
-
RESPONSE_MIME_TYPE
public static final String RESPONSE_MIME_TYPE
- See Also:
- Constant Field Values
-
PARAMETER_MODEL
public static final String PARAMETER_MODEL
- See Also:
- Constant Field Values
-
OPTION_MODEL_FULL
public static final String OPTION_MODEL_FULL
- See Also:
- Constant Field Values
-
OPTION_MODEL_USER_ACCOUNTS
public static final String OPTION_MODEL_USER_ACCOUNTS
- See Also:
- Constant Field Values
-
-
Method Detail
-
requiredActions
protected AuthorizationRequest requiredActions(VitroRequest vreq)
Description copied from class:VitroAjaxControllerBy default, a controller requires authorization for no actions. Subclasses that require authorization to process their page will override to return the actions that require authorization. In some cases, the choice of actions will depend on the contents of the request.- Overrides:
requiredActionsin classVitroAjaxController
-
doRequest
protected void doRequest(VitroRequest vreq, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, IOException
Description copied from class:VitroAjaxControllerSub-classes must implement this method to handle both GET and POST requests.- Specified by:
doRequestin classVitroAjaxController- Throws:
javax.servlet.ServletExceptionIOException
-
-