| 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectcom.bankframe.bo.DataPacket
The DataPacket class. This class is used to store data. Each element in the DataPacket is held and located through a string key. The DataPacket can hold any object instance.
| Field Summary | |
static java.lang.String | 
DATA_PACKET_NAME
An ease-of-use constant for specifing the DataPacket's string name.  | 
static java.lang.String | 
OWNER
An ease-of-use constant for specifing the DataPacket's owner.  | 
static java.lang.String | 
REQUEST_ID
An ease-of-use constant for specifing the DataPacket's request_id.  | 
| Constructor Summary | |
DataPacket()
The default class constructor.  | 
|
DataPacket(java.lang.String name)
The class constructor.  | 
|
| Method Summary | |
static DataPacket | 
append(DataPacket data,
       DataPacket dataToAppend)
This method adds a datapacket's contents to another datapacket.  | 
 void | 
clear()
This method clears this datapacket so that it contains no keys.  | 
 boolean | 
contains(java.lang.Object value)
This method tests if some key maps into the specified value in the datapacket.  | 
 boolean | 
containsKey(java.lang.Object key)
This method tests if the specified object is a key in this datapacket.  | 
 java.util.Enumeration | 
elements()
This method returns an enumeration of the values in this datapacket.  | 
 boolean | 
equals(java.lang.Object o)
This method tests if the DataPacket is equal to another DataPacket  | 
 java.lang.Object | 
get(java.lang.Object key)
This method returns the value to which the specified key is mapped in this datapacket.  | 
 java.lang.String | 
getName()
This method returns the string name of the data packet.  | 
 java.lang.String | 
getString(java.lang.Object key)
This method returns the value to which the specified key is mapped in this datapacket.  | 
 int | 
hashCode()
This method calculates the hash-code for the DataPacket  | 
 boolean | 
isEmpty()
This method tests if this datapacket maps no keys to values.  | 
 java.util.Enumeration | 
keys()
This method returns an enumeration of the keys in this datapacket.  | 
 java.lang.Object | 
put(java.lang.String key,
    java.lang.Object value)
This method provides a put that requires data keys to be strings.  | 
 java.lang.Object | 
remove(java.lang.Object key)
This method removes the key and its corresponding value from this datapacket.  | 
 void | 
setName(java.lang.String name)
This method sets the name of the data packet.  | 
 int | 
size()
This method returns the number of keys in this datapacket.  | 
 java.util.Vector | 
toList(boolean print)
This method returns the contents of this instance of the DataPacket class in a vector, where each element in the vector is a string in the format: 'key=value'.  | 
 void | 
toListInOrder(java.lang.String[] order)
This method prints the contents of this instance to the system console.  | 
 java.lang.String | 
toString()
Represents the object as a string.  | 
| Methods inherited from class java.lang.Object | 
getClass, notify, notifyAll, wait, wait, wait | 
| Field Detail | 
public static final java.lang.String DATA_PACKET_NAME
public static final java.lang.String REQUEST_ID
public static final java.lang.String OWNER
| Constructor Detail | 
public DataPacket()
public DataPacket(java.lang.String name)
name - the string name of this instance.| Method Detail | 
public boolean equals(java.lang.Object o)
o - is the other DataPacket to compare
public int hashCode()
public static DataPacket append(DataPacket data,
                                DataPacket dataToAppend)
data - com.bankframe.bo.DataPacketdataToAppend - com.bankframe.bo.DataPacket
public void clear()
public boolean contains(java.lang.Object value)
value - java.lang.Object the value to search for in the datapacket
public boolean containsKey(java.lang.Object key)
key - java.lang.Object the key to search for in the datapacket
public java.util.Enumeration elements()
public java.lang.Object get(java.lang.Object key)
key - java.lang.Object the key to retrieve from the datapacket
public java.lang.String getName()
public java.lang.String getString(java.lang.Object key)
key - java.lang.String
public boolean isEmpty()
public java.util.Enumeration keys()
public java.lang.Object put(java.lang.String key,
                            java.lang.Object value)
key - the string key.value - the object to be stored.
public java.lang.Object remove(java.lang.Object key)
key - the key that needs to be removed.
public void setName(java.lang.String name)
name - the string name of this instance.public int size()
public java.util.Vector toList(boolean print)
print - the contents of this instance to the system out console.
public void toListInOrder(java.lang.String[] order)
order - the string array order for printing this instance's contents.public java.lang.String toString()
  | 
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||