public final class InvocationBroker extends java.lang.Object implements IOperator
| Modifier and Type | Field and Description |
|---|---|
static int |
EVENT_BROKER_SHUTDOWN
The event constant that denotes that the broker is performing a shutdown.
|
static java.lang.String |
PROPERTY_DEVICE_IDENTIFIER
This property is used to derive the local system id upon startup.
|
static java.lang.String |
PROPERTY_DEVICE_NAME
This is the name of the system property that provides the human readable device
name.
|
static java.lang.String |
PROPERTY_DEVICE_TYPE
This is the name of the system property that provides the device type.
|
static java.lang.String |
PROPERTY_THREAD_DEFAULT
This is the name of the system property that describes the default number of
threads.
|
static java.lang.String |
PROPERTY_THREAD_MAXIMUM
This is the name of the system property that describes the maximum number of
threads.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addBrokerListener(int types,
IListener listener)
Adds a listener that listeners to certain types of events from the
broker.
|
DeviceRegistry |
getDeviceRegistry()
Returns the device registry of this invocation broker.
|
static InvocationBroker |
getInstance()
Returns the invocation broker of this JVM.
|
ObjectRegistry |
getObjectRegistry()
Returns the local object registry of this invocation broker.
|
PluginManager |
getPluginManager()
Returns the plugin manager of this invocation broker.
|
void |
invoke(Invocation invocation)
Called to perform a synchronous call.
|
void |
performOperation(IOperation operation)
Called by some plug-in or application to execute an operation.
|
void |
performOperation(IOperation operation,
IMonitor monitor)
Called by some plug-in or application to execute an operation.
|
boolean |
removeBrokerListener(int types,
IListener listener)
Removes a previously registered broker listener from the set of
broker listeners for the specified types of events.
|
void |
shutdown()
Performs a shutdown of the broker.
|
public static final java.lang.String PROPERTY_DEVICE_IDENTIFIER
public static final java.lang.String PROPERTY_DEVICE_NAME
public static final java.lang.String PROPERTY_DEVICE_TYPE
public static final java.lang.String PROPERTY_THREAD_MAXIMUM
public static final java.lang.String PROPERTY_THREAD_DEFAULT
public static final int EVENT_BROKER_SHUTDOWN
public static InvocationBroker getInstance()
public DeviceRegistry getDeviceRegistry()
public ObjectRegistry getObjectRegistry()
public PluginManager getPluginManager()
public void invoke(Invocation invocation)
invocation - The invocation to perform synchronously.public void performOperation(IOperation operation)
performOperation in interface IOperatoroperation - The operation to executed by some free thread.java.lang.NullPointerException - Thrown if the operation is null.public void performOperation(IOperation operation, IMonitor monitor)
performOperation in interface IOperatoroperation - The operation to executed by some free thread.monitor - The monitor used to interface with the operation.java.lang.NullPointerException - Thrown if the operation is null.
If the monitor is null, the broker will create a default
monitor.public void addBrokerListener(int types,
IListener listener)
types - The types of events to register for.listener - The listener to register.public boolean removeBrokerListener(int types,
IListener listener)
types - The types of events to unregister.listener - The listener to unregister.public void shutdown()