ActionReceiver Class Reference

List of all members.

Public Member Functions

 ActionReceiver (int tcpipPort, ClientServerType type)
 Will only accept actions from the localhost.
 ActionReceiver (int tcpipPort, ClientServerType type, String...trusted)
void addActionHandler (ActionHandler handler)
 Add another listener that handles received actions.
String getHostAddress ()
String getHostName ()
void setConnectionListener (ActionReceiverConnectionListener listener)
void stopDaemon ()
 Tell the server to stop sending actions.

Static Public Member Functions

static void startDaemons ()
 Unlike the pen servers, it's probably OK to start both a java and text server.
static void startDaemons (int tcpipPortJava, int tcpipPortPlainText)
static void stopDaemons ()
 Kill one or both servers.

Static Public Attributes

static final String CONFIG_FILE_KEY = "actionreceiver.trustedsenders"
 Read our trusted senders from this config file (see Configuration.java).
static final String CONFIG_FILE_VALUE = "/config/ActionReceiver.xml"
static final int DEFAULT_JAVA_PORT = Constants.Ports.ACTION_RECEIVER_JAVA
 Will listen on this port for Java XML objects.
static final int DEFAULT_PLAINTEXT_PORT = Constants.Ports.ACTION_RECEIVER_PLAINTEXT
 Will listen on this port for text commands.

Detailed Description

A daemon that sits and waits for actions to come in over the wire. It then invokes those actions.

This software is distributed under the BSD License.

Author:
Ron B Yeh (ronyeh(AT)cs.stanford.edu)

Definition at line 36 of file ActionReceiver.java.


Constructor & Destructor Documentation

ActionReceiver ( int  tcpipPort,
ClientServerType  type 
)

Will only accept actions from the localhost.

Parameters:
type 
tcpipPortPlainText 

Definition at line 165 of file ActionReceiver.java.

Referenced by ActionReceiver.startDaemons().

ActionReceiver ( int  tcpipPort,
ClientServerType  type,
String...  trusted 
)

Parameters:
trusted a list of IPs, DNSs, or (todo) subnets that we trust...

Definition at line 173 of file ActionReceiver.java.


Member Function Documentation

void addActionHandler ( ActionHandler  handler  ) 

Add another listener that handles received actions.

Parameters:
handler 

Definition at line 204 of file ActionReceiver.java.

String getHostAddress (  ) 

Returns:

Definition at line 287 of file ActionReceiver.java.

String getHostName (  ) 

Returns:

Definition at line 294 of file ActionReceiver.java.

void setConnectionListener ( ActionReceiverConnectionListener  listener  ) 

Parameters:
listener 

Definition at line 414 of file ActionReceiver.java.

static void startDaemons ( int  tcpipPortJava,
int  tcpipPortPlainText 
) [static]

Parameters:
tcpipPortJava 
tcpipPortPlainText 

Definition at line 84 of file ActionReceiver.java.

References ActionReceiver.ActionReceiver().

static void startDaemons (  )  [static]

Unlike the pen servers, it's probably OK to start both a java and text server.

..

Definition at line 76 of file ActionReceiver.java.

References ActionReceiver.DEFAULT_JAVA_PORT, and ActionReceiver.DEFAULT_PLAINTEXT_PORT.


The documentation for this class was generated from the following file:
Generated on Sat Apr 14 18:21:40 2007 for R3 Paper Toolkit by  doxygen 1.4.7