public interface IDiscoveryManager extends IPluginManager
Modifier and Type | Field and Description |
---|---|
static int |
EVENT_PLUGIN_ADDED
The event constant that is used to propagate the addition of a plug-in.
|
static int |
EVENT_PLUGIN_REMOVED
The event constant that is used to propagate the removal of a plug-in.
|
Modifier and Type | Method and Description |
---|---|
void |
addPluginListener(int type,
IListener listener)
Adds a listener to the discovery manager.
|
IPacketConnector |
openGroup(short group)
Opens a group connector using all transceivers that sends and
receives data using the specified group.
|
IPacketConnector |
openGroup(short group,
short ability)
Opens a group connector using the specified transceiver.
|
void |
registerDevice(DeviceDescription device,
long ttl)
Registers a device description that has been discovered from a remote device.
|
void |
registerPlugin(SystemID id,
PluginDescription plugin,
long ttl)
Registers the specified plug-in description of the specified device.
|
boolean |
removePluginListener(int type,
IListener listener)
Removes the specified listener for the specified set of event types.
|
getDeviceDescription, getDevices, getPluginDescriptions
performOperation, performOperation
static final int EVENT_PLUGIN_ADDED
static final int EVENT_PLUGIN_REMOVED
void addPluginListener(int type, IListener listener)
type
- The type of event to register for. At the present time the
discovery manager supports EVENT_PLUGIN_ADDED and EVENT_PLUGIN_REMOVED
events.listener
- The listener to register for the specified events.boolean removePluginListener(int type, IListener listener)
type
- The types of events to unregister.listener
- The listener to unregister for the specified types of
events.IPacketConnector openGroup(short group)
group
- The group to use.IPacketConnector openGroup(short group, short ability)
group
- The group to use.ability
- The ability of the transceiver to use.void registerDevice(DeviceDescription device, long ttl)
device
- The device description of the device that announced the
descriptions.ttl
- The time to live.java.lang.NullPointerException
- Thrown if one of the parameters is null.void registerPlugin(SystemID id, PluginDescription plugin, long ttl)
id
- The id of the device.plugin
- The plug-in description to register.ttl
- The time to live.java.lang.NullPointerException
- Thrown if one of the parameters is null.