Package org.apache.solr.core
Class RequestHandlers
- java.lang.Object
-
- org.apache.solr.core.RequestHandlers
-
public final class RequestHandlers extends Object
-
-
Constructor Summary
Constructors Constructor Description RequestHandlers(SolrCore core)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
SolrRequestHandler
get(String handlerName)
PluginBag<SolrRequestHandler>
getRequestHandlers()
Returns an unmodifiable Map containing the registered handlersstatic String
normalize(String p)
Trim the trailing '/' if it's there, and convert null to empty string.SolrRequestHandler
register(String handlerName, SolrRequestHandler handler)
Handlers must be initialized before calling this function.
-
-
-
Constructor Detail
-
RequestHandlers
public RequestHandlers(SolrCore core)
-
-
Method Detail
-
normalize
public static String normalize(String p)
Trim the trailing '/' if it's there, and convert null to empty string.we want: /update/csv and /update/csv/ to map to the same handler
-
get
public SolrRequestHandler get(String handlerName)
- Returns:
- the RequestHandler registered at the given name
-
register
public SolrRequestHandler register(String handlerName, SolrRequestHandler handler)
Handlers must be initialized before calling this function. As soon as this is called, the handler can immediately accept requests.This call is thread safe.
- Returns:
- the previous handler at the given path or null
-
getRequestHandlers
public PluginBag<SolrRequestHandler> getRequestHandlers()
Returns an unmodifiable Map containing the registered handlers
-
close
public void close()
-
-