Interface ServiceLookup<S extends Service<?>,SCTX>

Type Parameters:
S - The type to be used for the Service.
SCTX - The type to be used for the Service's context.
All Known Subinterfaces:
ServiceDirectory<S,SCTX>
All Known Implementing Classes:
ServiceDirectoryImpl, ServiceLookupImpl

public interface ServiceLookup<S extends Service<?>,SCTX>
The interface may be used internally by a system managing services. Having access to an object providing this interface such a system can "work" with the services and them configurations.
  • Method Details

    • getServiceDescriptors

      Set<ServiceDescriptor<S,SCTX>> getServiceDescriptors()
      Returns a collection containing the ServiceDescriptor instances known by the ServiceLookup.
      Returns:
      A collection containing the ServiceDescriptor instances known by the ServiceLookup.
    • hasService

      boolean hasService(ServiceDescriptor<S,SCTX> aServiceDescriptor)
      Determines whether the given service is known by the service bus by taking the service type and the service Meta-Data as criteria, not the service identity. I.e. there must not be the same service twice on the service bus which can not be distinguished by its type and its Meta-Data (i.e. a matcher must be able to distinguish two services from each other).
      Parameters:
      aServiceDescriptor - the service descriptor
      Returns:
      True in case the given service is known by the service bus.