Package org.apache.solr.api
Class Api
- java.lang.Object
-
- org.apache.solr.api.Api
-
- All Implemented Interfaces:
org.apache.solr.common.SpecProvider
- Direct Known Subclasses:
AnnotatedApi
,ApiBag.IntrospectApi
,ApiBag.LazyLoadedApi
,ApiBag.ReqHandlerToApi
,V2HttpCall.CompositeApi
public abstract class Api extends Object implements org.apache.solr.common.SpecProvider
Every version 2 API must extend the this class. It's mostly like a request handler but it has extra methods to provide the json schema of the end point
-
-
Field Summary
Fields Modifier and Type Field Description protected Map<String,org.apache.solr.common.util.JsonSchemaValidator>
commandSchema
protected org.apache.solr.common.SpecProvider
spec
-
Constructor Summary
Constructors Modifier Constructor Description protected
Api(org.apache.solr.common.SpecProvider spec)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract void
call(SolrQueryRequest req, SolrQueryResponse rsp)
The method that gets called for each requestMap<String,org.apache.solr.common.util.JsonSchemaValidator>
getCommandSchema()
This method helps to cache the schema validator objectorg.apache.solr.common.util.ValidatingJsonMap
getSpec()
Get the specification of the API as a Map
-
-
-
Method Detail
-
getCommandSchema
public Map<String,org.apache.solr.common.util.JsonSchemaValidator> getCommandSchema()
This method helps to cache the schema validator object
-
call
public abstract void call(SolrQueryRequest req, SolrQueryResponse rsp)
The method that gets called for each request
-
getSpec
public org.apache.solr.common.util.ValidatingJsonMap getSpec()
Get the specification of the API as a Map- Specified by:
getSpec
in interfaceorg.apache.solr.common.SpecProvider
-
-