All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class com.extropia.net.JavaCGIBridgeNotify

java.lang.Object
   |
   +----com.extropia.net.JavaCGIBridgeNotify

public class JavaCGIBridgeNotify
extends Object
This class is sent to Observers of the JavaCGIBridge whenever more data has been received by the JavaCGIBridge or the HTTP response has completed.

It is also sent when the JavaCGIBridge recognizes that a timeout has occured. Since threads cannot directly throw an exception to observers, this is the thread's mechanism for performing this notification.

Version:
2.00, 18 Jul 1998
Author:
Gunther Birznieks, Marty Hall


Variable Index

 o _data
_data is an object which contains the data being sent from the JavaCGIBridge class.
 o _endData
_endData is a flag indicating whether this message was sent in the middle of receiving the HTTP response or at the end of the whole data transmission.

Constructor Index

 o JavaCGIBridgeNotify(Object, boolean)
Constructs the object with the data object and the flag indicating whether we are at the end of the HTTP response.

Method Index

 o getData()
Returns the object that was sent in this notification object regardless of whether it is a Vector, byte array, or a JavaCGIBridgeTimeOutException object.
 o getParsedData()
Returns parsed Vector data if parsed data is expected to be returned.
 o getRawData()
Returns an array of bytes for the raw data sent so far if raw data is expected to be received.
 o isAtEndOfData()
Returns true if the JavaCGIBridge object has reached the end of the HTTP response.
 o isTimedOut()
Returns true if the JavaCGIBridge object passed the time limit for receiving data.

Variables

 o _data
 private Object _data
_data is an object which contains the data being sent from the JavaCGIBridge class. It will either be a Vector of Vectors for parsed data, a byte array for raw data, or a JavaCGIBridgeTimeOutException object for timeout notifications.

 o _endData
 private boolean _endData
_endData is a flag indicating whether this message was sent in the middle of receiving the HTTP response or at the end of the whole data transmission.

Constructors

 o JavaCGIBridgeNotify
 public JavaCGIBridgeNotify(Object data,
                            boolean endData)
Constructs the object with the data object and the flag indicating whether we are at the end of the HTTP response.

Methods

 o isAtEndOfData
 public boolean isAtEndOfData()
Returns true if the JavaCGIBridge object has reached the end of the HTTP response.

Returns:
boolean Flag indicating whether the end of HTTP response was set.
 o isTimedOut
 public boolean isTimedOut()
Returns true if the JavaCGIBridge object passed the time limit for receiving data.

Returns:
boolean Flag indicating whether the JavaCGIBridge timed out.
 o getParsedData
 public Vector getParsedData()
Returns parsed Vector data if parsed data is expected to be returned.

null will be returned if the data inside this object is not a Vector.

Returns:
Vector containing parsed data from JavaCGIBridge
 o getRawData
 public byte[] getRawData()
Returns an array of bytes for the raw data sent so far if raw data is expected to be received.

null will be returned if the data inside this object is not a byte array.

Returns:
byte [] containing raw data from JavaCGIBridge
 o getData
 public Object getData()
Returns the object that was sent in this notification object regardless of whether it is a Vector, byte array, or a JavaCGIBridgeTimeOutException object.

Returns:
Object the data sent from JavaCGIBridge

All Packages  Class Hierarchy  This Package  Previous  Next  Index