flashgateway.io
Class ASObject

java.lang.Object
  extended byjava.util.AbstractMap
      extended byjava.util.HashMap
          extended byflashgateway.io.ASObject
All Implemented Interfaces:
java.lang.Cloneable, java.util.Map, java.io.Serializable
Direct Known Subclasses:
AMFError, ASRecordSet

public class ASObject
extends java.util.HashMap

Implementation of MM's flashgateway.io.ASObject so that we can use ASTranslator

Version:
$Revision: 1.11 $, $Date: 2004/02/06 02:48:59 $
Author:
Jason Calabrese , Sean C. Sullivan
See Also:
Serialized Form

Constructor Summary
ASObject()
           
ASObject(java.lang.String type)
          Creates ASObject with type
 
Method Summary
 boolean containsKey(java.lang.Object key)
          Returns true if this map contains a mapping for the specified key.
 java.lang.Object get(java.lang.Object key)
          Returns the value to which the specified key is mapped in this identity hash map, or null if the map contains no mapping for this key.
 java.lang.String getType()
          Gets object type
 java.lang.Object instantiate()
           
 java.lang.Object put(java.lang.Object key, java.lang.Object value)
          Associates the specified value with the specified key in this map.
 java.lang.Object remove(java.lang.Object key)
          Removes the mapping for this key from this map if present.
 void setType(java.lang.String type)
          Sets object type
 java.lang.String toString()
           
 
Methods inherited from class java.util.HashMap
clear, clone, containsValue, entrySet, isEmpty, keySet, putAll, size, values
 
Methods inherited from class java.util.AbstractMap
equals, hashCode
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.util.Map
equals, hashCode
 

Constructor Detail

ASObject

public ASObject()

ASObject

public ASObject(java.lang.String type)
Creates ASObject with type

Parameters:
type -
Method Detail

getType

public java.lang.String getType()
Gets object type

Returns:
@see #setType(String)

setType

public void setType(java.lang.String type)
Sets object type

Parameters:
type -
See Also:
getType()

containsKey

public boolean containsKey(java.lang.Object key)
Returns true if this map contains a mapping for the specified key.

Parameters:
key - The key whose presence in this map is to be tested
Returns:
true if this map contains a mapping for the specified key.

get

public java.lang.Object get(java.lang.Object key)
Returns the value to which the specified key is mapped in this identity hash map, or null if the map contains no mapping for this key. A return value of null does not necessarily indicate that the map contains no mapping for the key; it is also possible that the map explicitly maps the key to null. The containsKey method may be used to distinguish these two cases.

Parameters:
key - the key whose associated value is to be returned.
Returns:
the value to which this map maps the specified key, or null if the map contains no mapping for this key.
See Also:
put(Object, Object)

put

public java.lang.Object put(java.lang.Object key,
                            java.lang.Object value)
Associates the specified value with the specified key in this map. If the map previously contained a mapping for this key, the old value is replaced.

Parameters:
key - key with which the specified value is to be associated.
value - value to be associated with the specified key.
Returns:
previous value associated with specified key, or null if there was no mapping for key. A null return can also indicate that the HashMap previously associated null with the specified key.

remove

public java.lang.Object remove(java.lang.Object key)
Removes the mapping for this key from this map if present.

Parameters:
key - key whose mapping is to be removed from the map.
Returns:
previous value associated with specified key, or null if there was no mapping for key. A null return can also indicate that the map previously associated null with the specified key.

instantiate

public java.lang.Object instantiate()
Returns:
this method may return null
See Also:
setType(String), getType()

toString

public java.lang.String toString()