public class SharedServiceRegistryKF
extends ej.service.registry.SimpleServiceRegistry
implements ej.wadapps.service.SharedServiceRegistry, ej.kf.FeatureStateListener
This service registry is able to handle the following kind of services:
Proxy
instancesConstructor and Description |
---|
SharedServiceRegistryKF()
Creates a shared service registry.
|
Modifier and Type | Method and Description |
---|---|
<T> T |
getService(java.lang.Class<T> serviceClass)
Gets the registered implementation for the given service.
|
<T> void |
register(java.lang.Class<T> serviceClass,
T implementation) |
void |
stateChanged(ej.kf.Feature feature,
ej.kf.Feature.State previousState) |
<T> void |
unregister(java.lang.Class<T> serviceClass,
T implementation) |
public SharedServiceRegistryKF()
public <T> void register(java.lang.Class<T> serviceClass, T implementation)
register
in interface ej.service.ServiceRegistry
register
in class ej.service.registry.SimpleServiceRegistry
public <T> void unregister(java.lang.Class<T> serviceClass, T implementation)
unregister
in interface ej.service.ServiceRegistry
unregister
in class ej.service.registry.SimpleServiceRegistry
@Nullable public <T> T getService(java.lang.Class<T> serviceClass)
getService
in interface ej.service.ServiceLoader
getService
in class ej.service.loader.SimpleServiceLoader
T
- the service type.serviceClass
- the service to found.null
if no implementation is available.public void stateChanged(@Nullable ej.kf.Feature feature, @Nullable ej.kf.Feature.State previousState)
stateChanged
in interface ej.kf.FeatureStateListener