Class ServiceRegistry
java.lang.Object
org.apache.tinkerpop.gremlin.structure.service.ServiceRegistry
- All Implemented Interfaces:
AutoCloseable,Service,Service.DirectoryService,Service.ServiceFactory
- Direct Known Subclasses:
TinkerServiceRegistry
A basic service registry implementation used by
CallStep. This service registry contains one meta-service -
the Service.DirectoryService, which is used to list and describe registered callable services.- Author:
- Mike Personick (http://github.com/mikepersonick)
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.tinkerpop.gremlin.structure.service.Service
Service.DirectoryService<I>, Service.Exceptions, Service.ServiceCallContext, Service.ServiceFactory<I,R>, Service.Type Nested classes/interfaces inherited from interface org.apache.tinkerpop.gremlin.structure.service.Service.DirectoryService
Service.DirectoryService.Params -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ServiceRegistryEmpty instance, for theGraphinterface.Fields inherited from interface org.apache.tinkerpop.gremlin.structure.service.Service.DirectoryService
NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcheckRegisteredService(String service) Check for non-null and registered.voidclose()Services can implement cleanup/shutdown procedures here.protected Stringdescribe(Service.ServiceFactory service) Provide a service description for the supplied service.execute(Service.ServiceCallContext ctx, Map params) Service.DirectoryServiceexecution.Lookup a service by name.registerService(Service.ServiceFactory serviceFactory) Register a callable service.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.tinkerpop.gremlin.structure.service.Service
execute, execute, getMaxBarrierSize, getRequirements, isBarrier, isStart, isStreamingMethods inherited from interface org.apache.tinkerpop.gremlin.structure.service.Service.DirectoryService
createService, describeParams, getName, getSupportedTypes, getTypeMethods inherited from interface org.apache.tinkerpop.gremlin.structure.service.Service.ServiceFactory
getRequirements, getRequirementsByType
-
Field Details
-
EMPTY
Empty instance, for theGraphinterface.
-
-
Constructor Details
-
ServiceRegistry
public ServiceRegistry()
-
-
Method Details
-
registerService
Register a callable service. -
checkRegisteredService
Check for non-null and registered. -
get
Lookup a service by name. -
execute
Service.DirectoryServiceexecution. List or describe the registered callable services.- Specified by:
executein interfaceService- Specified by:
executein interfaceService.DirectoryService
-
describe
Provide a service description for the supplied service. -
close
public void close()Description copied from interface:ServiceServices can implement cleanup/shutdown procedures here.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceService- Specified by:
closein interfaceService.DirectoryService- Specified by:
closein interfaceService.ServiceFactory
-