public abstract class DeviceServiceRegistry
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static void |
announceDeviceBye(LocalDevice device) |
static void |
announceDeviceChangedAndBuildUp(LocalDevice device) |
static void |
announceDeviceRunningAndBuildUp(LocalDevice device) |
static boolean |
checkAndUpdateAppSequence(EndpointReference ref,
AppSequence seq)
Returns true if the buffer for the application sequence is up to date.
|
static ServiceReference |
createServiceReference(EndpointReference epr,
SecurityKey securityKey,
QNameSet portTypes,
ConnectionInfo connectionInfo,
java.lang.String comManId)
Return a service reference for given epr, security key, port types.
|
static void |
decAppSequenceUser()
Decreases the app sequence buffer.
|
static DataStructure |
getAllRegisteredDevices() |
static DeviceReference |
getDeviceReference(DeviceReference oldDevRef,
SecurityKey newKey) |
static DeviceReference |
getDeviceReference(EndpointReference epr,
SecurityKey securityKey,
java.lang.String comManId)
Get device reference of a device location is unknown for given epr and security key.
|
static DeviceReference |
getDeviceReference(EndpointReference epr,
SecurityKey securityKey,
java.lang.String comManId,
boolean doCreate)
Returns the device reference to the specified endpoint reference.
|
static DeviceReference |
getDeviceReference(EndpointReference epr,
SecurityKey securityKey,
XAddressInfoSet addresses,
java.lang.String comManId,
boolean doCreate)
Returns the device reference for the specified endpoint reference, security key and xaddresses.
|
static DeviceReference |
getDeviceReference(EndpointReference epr,
XAddressInfoSet addresses,
java.lang.String comManId,
boolean doCreate)
Returns the device reference for the specified endpoint reference and xaddresses.
|
static DeviceReference |
getDeviceReference(HelloData helloData,
SecurityKey securityKey,
java.lang.String comManId)
Get device reference of a remote device if for incoming hello data and security key.
|
static DeviceReference |
getDeviceReference(LocalDevice device,
SecurityKey securityKey)
Get device reference of a local device and security key.
|
static LocalDevice |
getLocalDevice(EndpointReference epr,
SecurityKey securityKey)
Looks for local device of given epr and security key.
|
static DataStructure |
getLocalDeviceReferences(SearchParameter search)
Looks for local device reference for given search.
|
static LocalService |
getLocalService(Iterator eprInfoSet,
SecurityKey securityKey)
Looks for local service of given epr and security key.
|
static DataStructure |
getLocalServiceReferences(SearchParameter search)
Looks for local service references for given search.
|
static ServiceReference |
getServiceReference(DefaultServiceReference oldServRef,
SecurityKey newSecurityKey) |
static ServiceReference |
getServiceReference(EndpointReference epr,
SecurityKey securityKey,
java.lang.String comManId,
boolean doCreate) |
static DeviceReference |
getUpdatedDeviceReference(DiscoveryData newData,
SecurityKey key,
Message msg,
ConnectionInfo connectionInfo)
Update an matched device reference by new discovery data (e.g.
|
static ServiceReference |
getUpdatedServiceReference(HostedMData hosted,
EndpointReference parentDeviceEndpointReference,
SecurityKey securityKey,
ConnectionInfo connectionInfo,
java.lang.String comManId)
Looks for an service reference which should be updated.
|
static void |
incAppSequenceUser()
Increases the app sequence buffer.
|
static void |
register(DiscoveryBinding binding,
CommunicationManager manager)
Registers a discovery binding for lifecycle listening.
|
static void |
register(LocalDevice device)
Registers a local device.
|
static void |
register(LocalService service)
Registers a local service.
|
static void |
setDiscoveryData(LocalDevice device,
DiscoveryData discoveryData)
Set discovery date for an local device.
|
static void |
tearDown()
Stops all available communication manager, devices and services.
|
static void |
unregister(DiscoveryBinding binding,
CommunicationManager manager)
Unregisters a discovery binding for lifecycle listening.
|
static void |
unregister(LocalDevice device)
Unregisters a local device.
|
static void |
unregister(LocalService service)
Unregisters a local service.
|
static void |
unregisterDeviceReference(DefaultDeviceReference deviceReference)
Removes proxy device reference.
|
public static DataStructure getAllRegisteredDevices()
public static void tearDown()
public static DeviceReference getDeviceReference(HelloData helloData, SecurityKey securityKey, java.lang.String comManId)
helloData - ,combination of incoming hello and communication information.securityKey - ,security key for device reference.public static DeviceReference getDeviceReference(EndpointReference epr, SecurityKey securityKey, java.lang.String comManId)
epr - ,Endpoint reference of the device being looked for.securityKey - ,security key for device reference.public static DeviceReference getDeviceReference(EndpointReference epr, SecurityKey securityKey, java.lang.String comManId, boolean doCreate)
epr - , Endpoint reference of the device being looked for.securityKey - ,security key for device reference.doCreate - ,If true, reference will be created if not already existing.public static DeviceReference getDeviceReference(EndpointReference epr, XAddressInfoSet addresses, java.lang.String comManId, boolean doCreate)
epr - ,Endpoint reference of the device being looked for.doCreate - ,If true, reference will be created if not already existing.public static DeviceReference getDeviceReference(EndpointReference epr, SecurityKey securityKey, XAddressInfoSet addresses, java.lang.String comManId, boolean doCreate)
epr - ,Endpoint reference of the device being looked for.securityKey - ,security key for device reference.doCreate - ,If true, reference will be created if not already existing.public static DeviceReference getDeviceReference(DeviceReference oldDevRef, SecurityKey newKey)
public static DeviceReference getDeviceReference(LocalDevice device, SecurityKey securityKey)
device - ,local device which is being looked for. /**securityKey - ,security key for device reference.public static ServiceReference createServiceReference(EndpointReference epr, SecurityKey securityKey, QNameSet portTypes, ConnectionInfo connectionInfo, java.lang.String comManId) throws DuplicateServiceReferenceException
epr - ,endpoint reference of the service reference.securityKey - ,security key for device reference.portTypes - ,port types of the service reference.connectionInfo - comManId - DuplicateServiceReferenceExceptionpublic static ServiceReference getUpdatedServiceReference(HostedMData hosted, EndpointReference parentDeviceEndpointReference, SecurityKey securityKey, ConnectionInfo connectionInfo, java.lang.String comManId)
hosted - ,new hosted data.parentDeviceEndpointReference - ,endpoint reference of the parent device reference.securityKey - ,security key for device reference.connectionInfo - public static DeviceReference getUpdatedDeviceReference(DiscoveryData newData, SecurityKey key, Message msg, ConnectionInfo connectionInfo)
newData - ,discovery data for update a matching device reference.key - ,security key for device reference.msg - connectionInfo - public static ServiceReference getServiceReference(DefaultServiceReference oldServRef, SecurityKey newSecurityKey)
public static ServiceReference getServiceReference(EndpointReference epr, SecurityKey securityKey, java.lang.String comManId, boolean doCreate)
public static DataStructure getLocalDeviceReferences(SearchParameter search)
search - public static LocalDevice getLocalDevice(EndpointReference epr, SecurityKey securityKey) throws AuthorizationException
epr - ,endpoint reference of the local device.securityKey - ,security key for device reference.AuthorizationExceptionpublic static LocalService getLocalService(Iterator eprInfoSet, SecurityKey securityKey) throws AuthorizationException
eprInfoSet - ,EprInfoSet of the local service.securityKey - ,security key for device reference.AuthorizationExceptionpublic static DataStructure getLocalServiceReferences(SearchParameter search)
search - public static void unregisterDeviceReference(DefaultDeviceReference deviceReference)
deviceReference - proxy device reference to remove.public static void register(LocalDevice device)
device - ,local device to register.public static void unregister(LocalDevice device)
device - ,local device to unregister.public static void register(LocalService service)
service - ,local service to register.public static void unregister(LocalService service)
service - ,local service to unregister.public static void register(DiscoveryBinding binding, CommunicationManager manager)
binding - manager - public static void unregister(DiscoveryBinding binding, CommunicationManager manager)
binding - manager - public static void setDiscoveryData(LocalDevice device, DiscoveryData discoveryData)
device - ,local device where discovery data should be set.discoveryData - ,discovery which should be set.public static void announceDeviceChangedAndBuildUp(LocalDevice device)
public static void announceDeviceRunningAndBuildUp(LocalDevice device)
public static void announceDeviceBye(LocalDevice device)
public static boolean checkAndUpdateAppSequence(EndpointReference ref, AppSequence seq)
public static void incAppSequenceUser()
public static void decAppSequenceUser()