Interface DynamicServiceRegistration.DynamicServiceNotification<K>
-
- Type Parameters:
K- The key identifying a service type, i. e. a list of service instances.
- Enclosing class:
- DynamicServiceRegistration<K,S extends ADEPT2Service>
public static interface DynamicServiceRegistration.DynamicServiceNotification<K>This interface provides the means for signalling adding, updating and removing services to users of theDynamicServiceRegistration. All methods are being called while holding the write lock on @linkDynamicServiceRegistration.lock. So implementations should be rather short running and should avoid additional locks.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidaddedService(SessionToken session, K key, int index, URI[] uris, long contactTime)Notifies the adding of the designated service (URIs) for the designated key at the designated index of the corresponding service list.voidremovedService(SessionToken session, K key, int index, URI[] uris)Notifies the removal of the designated service (URIs) for the designated key at the designated index of the corresponding service list.voidremovedServices(SessionToken session, K key)Notifies the removal of all registered services for the designated key.voidupdatedServiceContact(SessionToken session, K key, int index, URI[] uris, long contactTime)Notifies the updating of (the contact time of) the designated service for the designated key at the designated index of the corresponding service list.
-
-
-
Method Detail
-
addedService
void addedService(SessionToken session, K key, int index, URI[] uris, long contactTime)
Notifies the adding of the designated service (URIs) for the designated key at the designated index of the corresponding service list.- Parameters:
session- The session token (or rather a child of it) with which the service has been added.key- The key for which the service has been added.index- The index of the service within the corresponding service list (of the designated key).uris- The URIs of the added service.contactTime- The last time the designated service has been contacted.0indicates that this service has not been contacted yet but just added.
-
updatedServiceContact
void updatedServiceContact(SessionToken session, K key, int index, URI[] uris, long contactTime)
Notifies the updating of (the contact time of) the designated service for the designated key at the designated index of the corresponding service list.- Parameters:
session- The session token (or rather a child of it) with which (the contact time of) the service has been updated.key- The key for which the service has been updated.index- The index of the service within the corresponding service list (of the designated key).uris- The URIs of the updated service.contactTime- The last time the designated service has been contacted.
-
removedService
void removedService(SessionToken session, K key, int index, URI[] uris)
Notifies the removal of the designated service (URIs) for the designated key at the designated index of the corresponding service list.- Parameters:
session- The session token (or rather a child of it) with which the service has been removed.key- The key for which the service has been removed.index- The index of the service within the corresponding service list (of the designated key).uris- The URIs of the removed service.
-
removedServices
void removedServices(SessionToken session, K key)
Notifies the removal of all registered services for the designated key.- Parameters:
session- The session token (or rather a child of it) with which the services have been removed.key- The key for which the services have been removed.
-
-