public interface IProvidedServicesFeature
Modifier and Type | Method and Description |
---|---|
void |
addInterceptor(IServiceInvocationInterceptor interceptor,
java.lang.Object service,
int pos)
Add a service interceptor.
|
void |
addMethodInvocationListener(IServiceIdentifier sid,
MethodInfo mi,
IMethodInvocationListener listener)
Add a method invocation handler.
|
IFuture<java.lang.Void> |
addService(java.lang.String name,
java.lang.Class<?> type,
java.lang.Object service)
Add a service to the container.
|
IFuture<java.lang.Void> |
addService(java.lang.String name,
java.lang.Class<?> type,
java.lang.Object service,
PublishInfo pi,
java.lang.String scope)
Add a service to the platform.
|
IFuture<java.lang.Void> |
addService(java.lang.String name,
java.lang.Class<?> type,
java.lang.Object service,
java.lang.String proxytype)
Add a service to the platform.
|
IServiceInvocationInterceptor[] |
getInterceptors(java.lang.Object service)
Get the interceptors of a service.
|
<T> T |
getProvidedService(java.lang.Class<T> clazz)
Get provided (declared) service.
|
<T> T |
getProvidedService(IServiceIdentifier sid)
Get the provided service implementation object by id.
|
IService |
getProvidedService(java.lang.String name)
Get provided (declared) service.
|
<T> T |
getProvidedServiceRawImpl(java.lang.Class<T> clazz)
Get the provided service implementation object by class.
|
java.lang.Object |
getProvidedServiceRawImpl(IServiceIdentifier sid)
Get the provided service implementation object by name.
|
java.lang.Object |
getProvidedServiceRawImpl(java.lang.String name)
Get the provided service implementation object by name.
|
<T> T[] |
getProvidedServices(java.lang.Class<T> clazz)
Get provided (declared) service.
|
boolean |
hasMethodListeners(IServiceIdentifier sid,
MethodInfo mi)
Test if service and method has listeners.
|
void |
notifyMethodListeners(IServiceIdentifier sid,
boolean start,
java.lang.Object proxy,
java.lang.reflect.Method method,
java.lang.Object[] args,
java.lang.Object callid,
ServiceInvocationContext context)
Notify listeners that a service method has been called.
|
void |
removeInterceptor(IServiceInvocationInterceptor interceptor,
java.lang.Object service)
Remove a service interceptor.
|
void |
removeMethodInvocationListener(IServiceIdentifier sid,
MethodInfo mi,
IMethodInvocationListener listener)
Remove a method invocation handler.
|
IFuture<java.lang.Void> |
removeService(IServiceIdentifier sid)
Removes a service from the container (shutdowns also the service if the container is running).
|
IFuture<java.lang.Void> addService(java.lang.String name, java.lang.Class<?> type, java.lang.Object service)
service
- The service.info
- The provided service info.IFuture<java.lang.Void> addService(java.lang.String name, java.lang.Class<?> type, java.lang.Object service, java.lang.String proxytype)
type
- The public service interface.service
- The service.type
- The proxy type (@see{BasicServiceInvocationHandler}).IFuture<java.lang.Void> addService(java.lang.String name, java.lang.Class<?> type, java.lang.Object service, PublishInfo pi, java.lang.String scope)
type
- The public service interface.service
- The service.scope
- The service scope.IFuture<java.lang.Void> removeService(IServiceIdentifier sid)
service
- The service identifier.IService getProvidedService(java.lang.String name)
name
- The service name.<T> T getProvidedService(java.lang.Class<T> clazz)
clazz
- The interface.<T> T getProvidedService(IServiceIdentifier sid)
name
- The service identifier.<T> T[] getProvidedServices(java.lang.Class<T> clazz)
clazz
- The interface (null for all services).<T> T getProvidedServiceRawImpl(java.lang.Class<T> clazz)
clazz
- The service clazz.java.lang.Object getProvidedServiceRawImpl(java.lang.String name)
name
- The service name.java.lang.Object getProvidedServiceRawImpl(IServiceIdentifier sid)
name
- The service identifier.void addMethodInvocationListener(IServiceIdentifier sid, MethodInfo mi, IMethodInvocationListener listener)
sid
- The service identifier.mi
- The method info.listener
- The method listener.void removeMethodInvocationListener(IServiceIdentifier sid, MethodInfo mi, IMethodInvocationListener listener)
sid
- The service identifier.mi
- The method info.listener
- The method listener.boolean hasMethodListeners(IServiceIdentifier sid, MethodInfo mi)
sid
- The service identifier.mi
- The method info.void notifyMethodListeners(IServiceIdentifier sid, boolean start, java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args, java.lang.Object callid, ServiceInvocationContext context)
void addInterceptor(IServiceInvocationInterceptor interceptor, java.lang.Object service, int pos)
interceptor
- The interceptor.service
- The service.pos
- The position (0=first, -1=last-1, i.e. one before method invocation).void removeInterceptor(IServiceInvocationInterceptor interceptor, java.lang.Object service)
interceptor
- The interceptor.service
- The service.IServiceInvocationInterceptor[] getInterceptors(java.lang.Object service)
service
- The service.