Class AMFDataContextDeserialize


  • public class AMFDataContextDeserialize
    extends Object

    AMF context used for deserialization

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addObject​(Object obj)
      Add an object to the object cache
      void addString​(String str)
      Add a string to the string cache
      void addTrait​(AMFDataTrait obj)
      Add a trait to the trait cache
      int clearIntData()
      Internal use, get and clear int data
      String getCharsetName()
      Get charset name used to deserialize strings (default is AMFDAta.AMF_DEFAULT_DESERIALIZE_CHARSETNAME = UTF-8)
      int getIntData()
      Internal use, get int data
      Object getObject​(int index)
      Get an object from the object cache
      int getObjectEncoding()
      Get object encoding, see AMFData.AMF_LEVEL*
      String getString​(int index)
      Get a string from the string cache
      AMFDataTrait getTrait​(int index)
      Get a trait from the trait cache
      boolean isAMF0()
      Is context AMF0
      boolean isAMF3()
      Is context AMF3
      boolean isIntData()
      Internal use, get int data
      void setCharsetName​(String charsetName)
      Set charset name used to deserialize strings (default is AMFDAta.AMF_DEFAULT_DESERIALIZE_CHARSETNAME = UTF-8)
      void setIntData​(int intData)
      Internal use, set int data
      void setObjectEncoding​(int objectEncoding)
      Set object encoding, see AMFData.AMF_LEVEL*
      • Methods inherited from class java.lang.Object

        clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • AMFDataContextDeserialize

        public AMFDataContextDeserialize()
        Constructor
      • AMFDataContextDeserialize

        public AMFDataContextDeserialize​(int objectEncoding)
        Constructor with encoding
        Parameters:
        objectEncoding - object encoding, see AMFData.AMF_LEVEL*
    • Method Detail

      • isIntData

        public boolean isIntData()
        Internal use, get int data
        Returns:
        returns true if pending int data
      • setIntData

        public void setIntData​(int intData)
        Internal use, set int data
        Parameters:
        intData - int data
      • getIntData

        public int getIntData()
        Internal use, get int data
        Returns:
        int data
      • clearIntData

        public int clearIntData()
        Internal use, get and clear int data
        Returns:
        int data
      • getObjectEncoding

        public int getObjectEncoding()
        Get object encoding, see AMFData.AMF_LEVEL*
        Returns:
        object encoding, see AMFData.AMF_LEVEL*
      • setObjectEncoding

        public void setObjectEncoding​(int objectEncoding)
        Set object encoding, see AMFData.AMF_LEVEL*
        Parameters:
        objectEncoding - object encoding, see AMFData.AMF_LEVEL*
      • isAMF3

        public boolean isAMF3()
        Is context AMF3
        Returns:
        true, if AMF3
      • isAMF0

        public boolean isAMF0()
        Is context AMF0
        Returns:
        true, if AMF0
      • addString

        public void addString​(String str)
        Add a string to the string cache
        Parameters:
        str - string value
      • getString

        public String getString​(int index)
                         throws IndexOutOfBoundsException
        Get a string from the string cache
        Parameters:
        index - index
        Returns:
        string value
        Throws:
        IndexOutOfBoundsException
      • addObject

        public void addObject​(Object obj)
        Add an object to the object cache
        Parameters:
        obj - object value
      • getObject

        public Object getObject​(int index)
                         throws IndexOutOfBoundsException
        Get an object from the object cache
        Parameters:
        index - index
        Returns:
        object value
        Throws:
        IndexOutOfBoundsException
      • addTrait

        public void addTrait​(AMFDataTrait obj)
        Add a trait to the trait cache
        Parameters:
        obj - trait object
      • getTrait

        public AMFDataTrait getTrait​(int index)
                              throws IndexOutOfBoundsException
        Get a trait from the trait cache
        Parameters:
        index - index
        Returns:
        trait object
        Throws:
        IndexOutOfBoundsException
      • getCharsetName

        public String getCharsetName()
        Get charset name used to deserialize strings (default is AMFDAta.AMF_DEFAULT_DESERIALIZE_CHARSETNAME = UTF-8)
        Returns:
        charset name used to decode/encode strings
      • setCharsetName

        public void setCharsetName​(String charsetName)
        Set charset name used to deserialize strings (default is AMFDAta.AMF_DEFAULT_DESERIALIZE_CHARSETNAME = UTF-8)
        Parameters:
        charsetName - charset name used to decode/encode strings