RTI Routing Service
Version 5.3.1
|
Adapter interface (required). More...
Public Member Functions | |
Connection | createConnection (String routingServiceName, String routingServiceGroupName, StreamReaderListener inputStreamDiscoveryListener, StreamReaderListener outputStreamDiscoveryListener, Properties properties) throws AdapterException |
Creates a Connection. | |
void | deleteConnection (Connection connection) throws AdapterException |
Deletes a Connection. | |
Version | getVersion () |
Returns the version of this adapter plugin. | |
Adapter interface (required).
Java adapters are registered with RTI Routing Service using the XML tag <java_adapter_plugin>
For example:
<dds> ... <adapter_library name="MyAdapterLib"> <java_adapter_plugin name="MyAdapterPlugin"> <class_name>com.rti.adapters.MyAdapter</class_name> </java_adapter_plugin> ... </adapter_library> ... <routing_service> ... </routing_service> ... </dds>
In the above example, the interface is implemented by the com.rti.adapters.MyAdapter class.
When RTI Routing Service creates a Java adapter, it uses a constructor with one java.lang.Properties parameter. Those properties contain the configuration of the adapter and, in addition, two special properties:
If that constructor is not found the constructor with no parameters is used instead.
Connection createConnection | ( | String | routingServiceName, |
String | routingServiceGroupName, | ||
StreamReaderListener | inputStreamDiscoveryListener, | ||
StreamReaderListener | outputStreamDiscoveryListener, | ||
Properties | properties | ||
) | throws AdapterException |
Creates a Connection.
A Connection provides access to a data domain (such as a DDS domain or a JMS network provider).
Connection objects are created when the domain routes that contain them are enabled.
In the XML configuration file, Connections are associated with the tags <connection_1> and <connection_2> within a domain route.
routingServiceName | <<in>> The routing service execution name. |
routingServiceGroupName | <<in>> The group name of the routing service execution. |
inputStreamDiscoveryListener | <<in>> The listener of the built-in StreamReader that notifies the discovery of new input streams. |
outputStreamDiscoveryListener | <<in>> The listener of the built-in StreamReader that notifies the discovery of new output streams. |
properties | <<in>> Configuration properties for the Connection. |
AdapterException | - if an error occurs. |
void deleteConnection | ( | Connection | connection | ) | throws AdapterException |
Deletes a Connection.
Connection objects are deleted when the domain routes that contain them are disabled or RTI Routing Service is closed.
connection | <<in>> Connection to be deleted |
AdapterException | - if an error occurs. |
Version getVersion | ( | ) |
Returns the version of this adapter plugin.