org.spicefactory.cinnamon.io.mapping
Enum ObjectEncoding

java.lang.Object
  extended by java.lang.Enum<ObjectEncoding>
      extended by org.spicefactory.cinnamon.io.mapping.ObjectEncoding
All Implemented Interfaces:
Serializable, Comparable<ObjectEncoding>

public enum ObjectEncoding
extends Enum<ObjectEncoding>

Enumeration for the type of object encoding. The encoding is determined by the type of class declaration for the ActionScript 3 class.

Author:
Jens Halm

Enum Constant Summary
DYNAMIC
          Encoding used for dynamic ActionScript classes.
EXTERNALIZABLE
          Encoding used for ActionScript classes that implement flash.utils.IExternalizable.
SEALED
          Encoding used for sealed ActionScript classes.
 
Method Summary
static ObjectEncoding fromByteCode(byte code)
          Returns the enum value for the specified type code byte.
 byte getCode()
          Returns the type code for this encoding as a byte value.
static ObjectEncoding valueOf(String name)
          Returns the enum constant of this type with the specified name.
static ObjectEncoding[] values()
          Returns an array containing the constants of this enum type, in the order they're declared.
 
Methods inherited from class java.lang.Enum
clone, compareTo, equals, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Enum Constant Detail

SEALED

public static final ObjectEncoding SEALED
Encoding used for sealed ActionScript classes.


EXTERNALIZABLE

public static final ObjectEncoding EXTERNALIZABLE
Encoding used for ActionScript classes that implement flash.utils.IExternalizable.


DYNAMIC

public static final ObjectEncoding DYNAMIC
Encoding used for dynamic ActionScript classes.

Method Detail

values

public static final ObjectEncoding[] values()
Returns an array containing the constants of this enum type, in the order they're declared. This method may be used to iterate over the constants as follows:
for(ObjectEncoding c : ObjectEncoding.values())
        System.out.println(c);

Returns:
an array containing the constants of this enum type, in the order they're declared

valueOf

public static ObjectEncoding valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)

Parameters:
name - the name of the enum constant to be returned.
Returns:
the enum constant with the specified name
Throws:
IllegalArgumentException - if this enum type has no constant with the specified name

getCode

public byte getCode()
Returns the type code for this encoding as a byte value.

Returns:
the type code for this encoding as a byte value

fromByteCode

public static ObjectEncoding fromByteCode(byte code)
Returns the enum value for the specified type code byte.

Parameters:
code - the type code byte
Returns:
the enum value for the specified type code byte