Public Member Functions | Protected Member Functions | Private Attributes
org.ros.concurrent.CancellableLoop Class Reference
Inheritance diagram for org.ros.concurrent.CancellableLoop:
Inheritance graph
[legend]

List of all members.

Public Member Functions

void cancel ()
 CancellableLoop ()
boolean isRunning ()
void run ()

Protected Member Functions

void handleInterruptedException (InterruptedException e)
abstract void loop () throws InterruptedException
void setup ()

Private Attributes

final Object mutex
boolean ranOnce = false
Thread thread

Detailed Description

An interruptable loop that can be run by an ExecutorService.

Author:
khughes@google.com (Keith M. Hughes)

Definition at line 28 of file CancellableLoop.java.


Constructor & Destructor Documentation

Definition at line 42 of file CancellableLoop.java.


Member Function Documentation

Interrupts the loop.

Definition at line 88 of file CancellableLoop.java.

void org.ros.concurrent.CancellableLoop.handleInterruptedException ( InterruptedException  e) [inline, protected]

An InterruptedException was thrown.

Reimplemented in org.ros.internal.transport.queue.MessageDispatcher< T >.

Definition at line 82 of file CancellableLoop.java.

Returns:
 true 
if the loop is running

Definition at line 97 of file CancellableLoop.java.

abstract void org.ros.concurrent.CancellableLoop.loop ( ) throws InterruptedException [protected, pure virtual]

Definition at line 47 of file CancellableLoop.java.

void org.ros.concurrent.CancellableLoop.setup ( ) [inline, protected]

The setup block for the loop. This will be called exactly once before the first call to loop().

Definition at line 69 of file CancellableLoop.java.


Member Data Documentation

boolean org.ros.concurrent.CancellableLoop.ranOnce = false [private]
 true 

if the code has been run once,

 false 

otherwise.

Definition at line 35 of file CancellableLoop.java.

The Thread the code will be running in.

Definition at line 40 of file CancellableLoop.java.


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


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