S
- The type to be used for the Service
.SCTX
- The type to be used for the Service
's context.public interface ServiceDirectory<S extends Service<?>,SCTX> extends ServiceLookup<S,SCTX>
Modifier and Type | Method and Description |
---|---|
void |
addService(ServiceDescriptor<S,SCTX> aServiceDescriptor)
Registers a service to the service bus.
|
void |
removeService(ServiceDescriptor<S,SCTX> aServiceDescriptor)
Unregisters a service to the service bus.
|
getServiceDescriptors, hasService
void addService(ServiceDescriptor<S,SCTX> aServiceDescriptor) throws DuplicateServiceRuntimeException
aService
- The service to be registeredDuplicateServiceRuntimeException
- in case the service cannot be
identified unambiguously by a matcher. A matcher declaration must
be possible to identify the given service unambiguously. The
service as being described by the service type and the service
meta data is already registered to the service bus.void removeService(ServiceDescriptor<S,SCTX> aServiceDescriptor) throws UnknownServiceRuntimeException
aService
- The service to be unregisteredUnknownServiceRuntimeException
- in case the service is not known.ServiceBusRuntimeException
- is case the service as being
described by the service type and the service meta data is not
registered to the service bus, aka "unknown".Copyright © 2016. All rights reserved.