ABLE 2.0.0 07/02/2003 10:25:01

com.ibm.able
Interface AbleDataBufferRemoteManager

All Superinterfaces:
java.io.Serializable

public interface AbleDataBufferRemoteManager
extends java.io.Serializable

The AbleDataBufferRemoteManager interface describes the unique behavior required of AbleRemoteBeans which pass data using data buffers. A bean implementing this interface has either an inputBuffer, an outputBuffer, or both. Buffers are collections or arrays, and are not necessarily indexable. A bean expecting to process data via data buffers has dataflow enabled.


Method Summary
 void addDestBufferConnection(AbleBufferConnection theAbleBufferConnection)
          Adds a destination buffer connection.
 void addSourceBufferConnection(AbleBufferConnection theAbleBufferConnection)
          Adds a source buffer connection.
 java.util.Vector getDestBufferConnections()
          Get the list of all destination (output) buffer connections.
 java.lang.Object getInputBuffer()
          Returns a reference to the input buffer.
 java.lang.Object getInputBuffer(int theIndex)
          Returns the value of a single element of the input buffer.
 java.lang.String[] getInputBufferAsStringArray()
          Gets the contents of the input buffer as an array of strings.
 java.util.Enumeration getInputBufferContents()
          Gets the contents of the input buffer as an enumeration.
 java.lang.Object getOutputBuffer()
          Returns a reference to the output buffer.
 java.lang.Object getOutputBuffer(int theIndex)
          Returns the value of a single element of the output buffer.
 java.lang.String[] getOutputBufferAsStringArray()
          Returns the contents of the output buffer as an array of Strings.
 java.util.Enumeration getOutputBufferContents()
          Returns the contents of the output buffer as an enumeration.
 java.util.Vector getSourceBufferConnections()
          Returns a list of all source (input) buffer connections.
 boolean hasInputBuffer()
          Indicates if this bean has an input buffer.
 boolean hasOutputBuffer()
          Indicates if this bean has an output buffer.
 boolean isConnectable()
          Indicates if this bean supports buffer connections.
 boolean isDataFlowEnabled()
          Indicates if the bean will process data in buffers.
 void processBufferConnections()
          Processes all buffer connections.
 void removeDestBufferConnection(AbleBufferConnection theAbleBufferConnection)
          Remove a destination buffer connection.
 void removeSourceBufferConnection(AbleBufferConnection theAbleBufferConnection)
          Removes a source buffer connection.
 void setDataFlowEnabled(boolean theDataFlowEnabledState)
          Sets the data flow processing state of the bean.
 void setInputBuffer(int theIndex, java.lang.Object theObject)
          Sets the value of a single element of the input buffer.
 void setInputBuffer(java.lang.Object theInputBuffer)
          Sets the input buffer to the specified object.
 void setOutputBuffer(int theIndex, java.lang.Object theObject)
          Sets the value of a single element of the output buffer.
 void setOutputBuffer(java.lang.Object theOutputBuffer)
          Sets the output buffer to the specified object.
 

Method Detail

setDataFlowEnabled

public void setDataFlowEnabled(boolean theDataFlowEnabledState)
                        throws java.rmi.RemoteException
Sets the data flow processing state of the bean.
Parameters:
theDataFlowEnabledState - Indicates if this bean will process data in buffers. When set to true, this bean will be included in its parent's process list.
Throws:
java.rmi.RemoteException - If an error occurs.

isDataFlowEnabled

public boolean isDataFlowEnabled()
                          throws java.rmi.RemoteException
Indicates if the bean will process data in buffers.
Returns:
true if the bean will process data in buffers; false otherwise.
Throws:
java.rmi.RemoteException - If an error occurs.

setInputBuffer

public void setInputBuffer(java.lang.Object theInputBuffer)
                    throws java.rmi.RemoteException
Sets the input buffer to the specified object.
Parameters:
theInputBuffer - Any object, such as a String[], Vector, Hashtable, and so on, that can act as a buffer of input data. A reference to the object is saved; the object is not cloned. Note that once the input buffer is set, it must not be tampered with while an AbleBean is reading data from it.

Throws:
java.rmi.RemoteException - If an error occurs.

getInputBuffer

public java.lang.Object getInputBuffer()
                                throws java.rmi.RemoteException
Returns a reference to the input buffer.
Returns:
A reference to the object that is the current input buffer, or null if no input buffer has been set.
Throws:
java.rmi.RemoteException - If an error occurs.

setInputBuffer

public void setInputBuffer(int theIndex,
                           java.lang.Object theObject)
                    throws java.rmi.RemoteException
Sets the value of a single element of the input buffer.
Parameters:
theIndex - The location in the input buffer to be set to the specified value.

theObject - The new value of the element at the specified location.

Throws:
java.rmi.RemoteException - If an error occurs or if the input buffer does not support indexing.

getInputBuffer

public java.lang.Object getInputBuffer(int theIndex)
                                throws java.rmi.RemoteException
Returns the value of a single element of the input buffer.
Parameters:
theIndex - The location to retrieve from the input buffer.

Throws:
java.rmi.RemoteException - If an error occurs or if the input buffer does not support indexing.

hasInputBuffer

public boolean hasInputBuffer()
                       throws java.rmi.RemoteException
Indicates if this bean has an input buffer.
Returns:
true if the input buffer has been set; that is, the buffer is not null; otherwise false is returned.
Throws:
java.rmi.RemoteException - If an error occurs.

getInputBufferAsStringArray

public java.lang.String[] getInputBufferAsStringArray()
                                               throws java.rmi.RemoteException
Gets the contents of the input buffer as an array of strings.
Returns:
An array of string values of the input buffer, or null if no input buffer has been sent.
Throws:
java.rmi.RemoteException - If an error occurs or if the input buffer cannot be converted to an array of string values.

getInputBufferContents

public java.util.Enumeration getInputBufferContents()
                                             throws java.rmi.RemoteException
Gets the contents of the input buffer as an enumeration.
Returns:
An enumeration of values from the input buffer, or null if no input buffer has been set.
Throws:
java.rmi.RemoteException - If an error occurs or if the input buffer cannot be returned as an enumeration.

setOutputBuffer

public void setOutputBuffer(java.lang.Object theOutputBuffer)
                     throws java.rmi.RemoteException
Sets the output buffer to the specified object.
Parameters:
theOutputBuffer - Any object, such as a String[], Vector, Hashtable, and so on, that can act as a buffer of output data. A reference to the object is saved; the object is not cloned. Note that once the output buffer is set, it must not be tampered with while an AbleBean is writing data to it.

Throws:
java.rmi.RemoteException - If an error occurs.

getOutputBuffer

public java.lang.Object getOutputBuffer()
                                 throws java.rmi.RemoteException
Returns a reference to the output buffer.
Returns:
A reference to the object that is the current output buffer, or null if no output buffer has been set.
Throws:
java.rmi.RemoteException - If an error occurs.

setOutputBuffer

public void setOutputBuffer(int theIndex,
                            java.lang.Object theObject)
                     throws java.rmi.RemoteException
Sets the value of a single element of the output buffer.
Parameters:
theIndex - The location in the output buffer to be set to the specified value.

theObject - The new value of the element at the specified location.

Throws:
java.rmi.RemoteException - If an error occurs or if the output buffer does not support indexing.

getOutputBuffer

public java.lang.Object getOutputBuffer(int theIndex)
                                 throws java.rmi.RemoteException
Returns the value of a single element of the output buffer.
Parameters:
theIndex - The location in the output buffer to be retrieved.

Returns:
The object at the specified location, or null if no output buffer exists or if the location does not contain a value.

Throws:
java.rmi.RemoteException - If an error occurs or if the output buffer does not support indexing.

hasOutputBuffer

public boolean hasOutputBuffer()
                        throws java.rmi.RemoteException
Indicates if this bean has an output buffer.
Returns:
true if the output buffer has been set; that is, the buffer is not null; otherwise false is returned.
Throws:
java.rmi.RemoteException - If an error occurs.

getOutputBufferAsStringArray

public java.lang.String[] getOutputBufferAsStringArray()
                                                throws java.rmi.RemoteException
Returns the contents of the output buffer as an array of Strings.
Returns:
An array of string values of the output buffer, or null if no output buffer has been set.
Throws:
java.rmi.RemoteException -  
java.rmi.RemoteException - If an error occurs or if the output buffer cannot be converted to an array of String values.

getOutputBufferContents

public java.util.Enumeration getOutputBufferContents()
                                              throws java.rmi.RemoteException
Returns the contents of the output buffer as an enumeration.
Returns:
An enumeration of the output buffer, or null if no output buffer has been set.
Throws:
java.rmi.RemoteException - If an error occurs or if the output buffer cannot be returned as an enumeration.

addSourceBufferConnection

public void addSourceBufferConnection(AbleBufferConnection theAbleBufferConnection)
                               throws java.rmi.RemoteException
Adds a source buffer connection.
Parameters:
theAbleBufferConnection - An AbleBufferConnection object including a bean whose output buffer populates this bean's input buffer.
Throws:
java.rmi.RemoteException - If an error occurs.

removeSourceBufferConnection

public void removeSourceBufferConnection(AbleBufferConnection theAbleBufferConnection)
                                  throws java.rmi.RemoteException
Removes a source buffer connection.
Parameters:
theAbleBufferConnection - The AbleBufferConnection object to be removed.
Throws:
java.rmi.RemoteException - If an error occurs.

getSourceBufferConnections

public java.util.Vector getSourceBufferConnections()
                                            throws java.rmi.RemoteException
Returns a list of all source (input) buffer connections. Typically only one of these connections is to an active bean.
Returns:
All source buffer connections.
Throws:
java.rmi.RemoteException - If an error occurs.

addDestBufferConnection

public void addDestBufferConnection(AbleBufferConnection theAbleBufferConnection)
                             throws java.rmi.RemoteException
Adds a destination buffer connection.
Parameters:
theAbleBufferConnection - An AbleBufferConnection object including a bean whose input buffer is to be populated from this bean's output buffer.
Throws:
java.rmi.RemoteException - If an error occurs.

removeDestBufferConnection

public void removeDestBufferConnection(AbleBufferConnection theAbleBufferConnection)
                                throws java.rmi.RemoteException
Remove a destination buffer connection.
Parameters:
theAbleBufferConnection - The AbleBufferConnection object to be removed.
Throws:
java.rmi.RemoteException - If an error occurs.

getDestBufferConnections

public java.util.Vector getDestBufferConnections()
                                          throws java.rmi.RemoteException
Get the list of all destination (output) buffer connections.
Returns:
All destination buffer connections.
Throws:
java.rmi.RemoteException - If an error occurs.

isConnectable

public boolean isConnectable()
                      throws java.rmi.RemoteException
Indicates if this bean supports buffer connections.
Returns:
true if this bean supports buffer connections; false otherwise.
Throws:
java.rmi.RemoteException - If an error occurs.

processBufferConnections

public void processBufferConnections()
                              throws java.rmi.RemoteException
Processes all buffer connections. Moves data from connected source beans' outputBuffers to this bean's inputBuffer.
Throws:
java.rmi.RemoteException - If an error occurs.

ABLE 2.0.0 07/02/2003 10:25:01

(C) Copyright IBM Corporation 1999, 2003