Classes | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | Static Private Attributes
org.ros.node.DefaultNodeMainExecutor Class Reference
Inheritance diagram for org.ros.node.DefaultNodeMainExecutor:
Inheritance graph
[legend]

List of all members.

Classes

class  RegistrationListener

Public Member Functions

void execute (final NodeMain nodeMain, final NodeConfiguration nodeConfiguration, final Collection< NodeListener > nodeListeners)
void execute (NodeMain nodeMain, NodeConfiguration nodeConfiguration)
ScheduledExecutorService getScheduledExecutorService ()
void shutdown ()
void shutdownNodeMain (NodeMain nodeMain)

Static Public Member Functions

static NodeMainExecutor newDefault ()
static NodeMainExecutor newDefault (ScheduledExecutorService executorService)

Private Member Functions

 DefaultNodeMainExecutor (NodeFactory nodeFactory, ScheduledExecutorService scheduledExecutorService)
void registerNode (ConnectedNode connectedNode)
void safelyShutdownNode (Node node)
void unregisterNode (Node node)

Private Attributes

final Multimap< GraphName,
ConnectedNode
connectedNodes
final NodeFactory nodeFactory
final BiMap< Node, NodeMainnodeMains
final ScheduledExecutorService scheduledExecutorService

Static Private Attributes

static final boolean DEBUG = false
static final Log log = LogFactory.getLog(DefaultNodeMainExecutor.class)

Detailed Description

Executes NodeMains in separate threads.

Author:
damonkohler@google.com (Damon Kohler)

Definition at line 42 of file DefaultNodeMainExecutor.java.


Constructor & Destructor Documentation

org.ros.node.DefaultNodeMainExecutor.DefaultNodeMainExecutor ( NodeFactory  nodeFactory,
ScheduledExecutorService  scheduledExecutorService 
) [inline, private]
Parameters:
nodeFactoryNodeFactory to use for node creation.
scheduledExecutorServiceNodeMains will be executed using this

Definition at line 98 of file DefaultNodeMainExecutor.java.


Member Function Documentation

void org.ros.node.DefaultNodeMainExecutor.execute ( final NodeMain  nodeMain,
final NodeConfiguration  nodeConfiguration,
final Collection< NodeListener nodeListeners 
) [inline]

Definition at line 119 of file DefaultNodeMainExecutor.java.

void org.ros.node.DefaultNodeMainExecutor.execute ( NodeMain  nodeMain,
NodeConfiguration  nodeConfiguration 
) [inline]

Executes the supplied NodeMain using the supplied NodeConfiguration.

Parameters:
nodeMainthe NodeMain to execute
nodeConfigurationthe NodeConfiguration that will be used to create the Node

Implements org.ros.node.NodeMainExecutor.

Definition at line 146 of file DefaultNodeMainExecutor.java.

Returns:
the ScheduledExecutorService that this NodeMainExecutor uses

Implements org.ros.node.NodeMainExecutor.

Definition at line 114 of file DefaultNodeMainExecutor.java.

Returns:
an instance of DefaultNodeMainExecutor that uses a ScheduledExecutorService that is suitable for both executing tasks immediately and scheduling tasks to execute in the future

Definition at line 80 of file DefaultNodeMainExecutor.java.

static NodeMainExecutor org.ros.node.DefaultNodeMainExecutor.newDefault ( ScheduledExecutorService  executorService) [inline, static]
Returns:
an instance of DefaultNodeMainExecutor that uses the supplied ExecutorService

Definition at line 88 of file DefaultNodeMainExecutor.java.

void org.ros.node.DefaultNodeMainExecutor.registerNode ( ConnectedNode  connectedNode) [inline, private]

Register a ConnectedNode with the NodeMainExecutor.

Parameters:
connectedNodethe ConnectedNode to register

Definition at line 196 of file DefaultNodeMainExecutor.java.

Trap and log any exceptions while shutting down the supplied Node.

Parameters:
nodethe Node to shut down

Definition at line 173 of file DefaultNodeMainExecutor.java.

Shutdown all started Nodes. This does not shut down the supplied ExecutorService.

Implements org.ros.node.NodeMainExecutor.

Definition at line 159 of file DefaultNodeMainExecutor.java.

Shuts down the supplied NodeMain (i.e. NodeMain#onShutdown(Node) will be called). This does not necessarily shut down the Node that is associated with the NodeMain.

This has no effect if the NodeMain has not started.

Parameters:
nodeMainthe NodeMain to shutdown

Implements org.ros.node.NodeMainExecutor.

Definition at line 151 of file DefaultNodeMainExecutor.java.

Unregister a Node with the NodeMainExecutor.

Parameters:
nodethe Node to unregister

Definition at line 215 of file DefaultNodeMainExecutor.java.


Member Data Documentation

Definition at line 49 of file DefaultNodeMainExecutor.java.

final boolean org.ros.node.DefaultNodeMainExecutor.DEBUG = false [static, private]

Definition at line 44 of file DefaultNodeMainExecutor.java.

final Log org.ros.node.DefaultNodeMainExecutor.log = LogFactory.getLog(DefaultNodeMainExecutor.class) [static, private]

Definition at line 45 of file DefaultNodeMainExecutor.java.

Definition at line 47 of file DefaultNodeMainExecutor.java.

Definition at line 50 of file DefaultNodeMainExecutor.java.

final ScheduledExecutorService org.ros.node.DefaultNodeMainExecutor.scheduledExecutorService [private]

Definition at line 48 of file DefaultNodeMainExecutor.java.


The documentation for this class was generated from the following file:


rosjava_core
Author(s):
autogenerated on Wed Aug 26 2015 16:06:51