ninja.activeproxy.path
Interface ConnectorIF

All Known Implementing Classes:
Connector, TCPConnector

public interface ConnectorIF

Interface for connectors.


Method Summary
 void createReader()
          Creates a reader for an operator.
 void createWriter(java.lang.Object info)
          Creates a writer for an operator.
 java.lang.Object getCommunicationInfo()
          Returns the information object.
 Operator getOperator()
          Returns the operator for which this connector creates a reader/writer.
 java.lang.Object getPathID()
          Returns the path ID of the path that will go through the operator.
 void setCommunicationInfo(java.lang.Object info)
          Sets the information object necessary for the previous operator in the path to setup its writer.
 void setOperator(Operator operator)
          Sets the operator for which this connector creates a reader/writer.
 void setOperatorReader(java.io.InputStream obj)
          Sets the reader of the operator.
 void setOperatorWriter(java.io.OutputStream obj)
          Sets the writer of the operator.
 void setPathID(java.lang.Object pathID)
          Sets the path ID of the path that will go through the operator.
 

Method Detail

setOperator

public void setOperator(Operator operator)
Sets the operator for which this connector creates a reader/writer.
Parameters:
operator - operator for which this connector creates a reader/writer.

getOperator

public Operator getOperator()
Returns the operator for which this connector creates a reader/writer.
Returns:
the operator for which this connector creates a reader/writer.

setPathID

public void setPathID(java.lang.Object pathID)
Sets the path ID of the path that will go through the operator.
Parameters:
pathID - path ID.

getPathID

public java.lang.Object getPathID()
Returns the path ID of the path that will go through the operator.
Returns:
path ID of the path that will go through the operator.

setOperatorReader

public void setOperatorReader(java.io.InputStream obj)
Sets the reader of the operator.
Parameters:
obj - input stream of the operator.

setOperatorWriter

public void setOperatorWriter(java.io.OutputStream obj)
Sets the writer of the operator.
Parameters:
obj - output stream of the operator.

setCommunicationInfo

public void setCommunicationInfo(java.lang.Object info)
Sets the information object necessary for the previous operator in the path to setup its writer. This could be an Integer class containing the port number on which there is a thread listening for incoming connections, a PipedInputStream for operators running on the same machine, etc.
Parameters:
info - information object.

getCommunicationInfo

public java.lang.Object getCommunicationInfo()
Returns the information object.
Returns:
information object.

createReader

public void createReader()
Creates a reader for an operator.

createWriter

public void createWriter(java.lang.Object info)
Creates a writer for an operator.
Parameters:
info - information object from the next operator in the path.