All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class semper.txlayer.context.TXQueues

java.lang.Object
   |
   +----java.lang.Thread
           |
           +----semper.txlayer.context.TXQueues

public class TXQueues
extends Thread
Objects of this class provide the following functionality: TXQueues are used internally by TXContexts and TXSubContexts.


Variable Index

 o _failed
On certain conditions this variable signals that reading or writing failed.

Constructor Index

 o TXQueues(SecComPoint, SecComPoint)
Create a Queue

Method Index

 o getMyCertificateContext()
 o getPeerCertificateContext()
 o read(CLAddress)
Reads an object from the channel
 o run()
This method constantly reads from the compoint and stores read objects in the Vectors in the hashtable.
 o write(Serializable, CLAddress)
Writes the object to the channel.

Variables

 o _failed
 public boolean _failed
On certain conditions this variable signals that reading or writing failed. The Thread is the stopped, no further operation is possible.

Constructors

 o TXQueues
 public TXQueues(SecComPoint cp_write,
                 SecComPoint cp_read)
Create a Queue

Methods

 o write
 public void write(Serializable m,
                   CLAddress claddress) throws TXContextCommException
Writes the object to the channel.

Parameters:
m - The serializable object to write
claddress - The claddress that servers as an channel identifier. The peer must read for the same claddress.
Throws: TXContextCommException
When the Channel does not want to write our object... .
 o read
 public Serializable read(CLAddress claddress) throws TXContextCommException
Reads an object from the channel

Returns:
The read object or null if there is no object for us in the queues. Callers must do a wait if they see a null.
Throws: TXContextCommException
When the Channel does not want to read an object.
 o run
 public void run()
This method constantly reads from the compoint and stores read objects in the Vectors in the hashtable. After a successful read all waiting objects are notified.

Overrides:
run in class Thread
 o getMyCertificateContext
 public CertificateContext getMyCertificateContext()
Returns:
A clone of my own certificates that are used in the connection. Might be null if no connection is established.
 o getPeerCertificateContext
 public CertificateContext getPeerCertificateContext()
Returns:
A clone of the peers certificates that are used in the connection. Might be null if no connection is established.

All Packages  Class Hierarchy  This Package  Previous  Next  Index