Class StreamObjectHeaderStart

    • Field Detail

      • STREAM_OBJECT_HEADER_START_16_BIT

        public static final int STREAM_OBJECT_HEADER_START_16_BIT
        Specify for 16-bit stream object header start.
        See Also:
        Constant Field Values
      • STREAM_OBJECT_HEADER_START_32_BIT

        public static final int STREAM_OBJECT_HEADER_START_32_BIT
        Specify for 32-bit stream object header start.
        See Also:
        Constant Field Values
      • headerType

        protected int headerType
        Gets or sets the type of the stream object. value 0 for 16-bit stream object header start, value 2 for 32-bit stream object header start.
      • compound

        protected int compound
        Gets or sets a value that specifies if set a compound parse type is needed and MUST be ended with either an 8-bit stream object header end or a 16-bit stream object header end. If the bit is zero, it specifies a single object. Otherwise it specifies a compound object.
      • length

        protected int length
    • Constructor Detail

      • StreamObjectHeaderStart

        protected StreamObjectHeaderStart()
        Initializes a new instance of the StreamObjectHeaderStart class.
      • StreamObjectHeaderStart

        protected StreamObjectHeaderStart​(StreamObjectTypeHeaderStart streamObjectTypeHeaderStart)
        Initializes a new instance of the StreamObjectHeaderStart class with specified header type.
        Parameters:
        streamObjectTypeHeaderStart - Specify the value of the StreamObjectHeaderStart Type.
    • Method Detail

      • tryParse

        public static int tryParse​(byte[] byteArray,
                                   int startIndex,
                                   AtomicReference<StreamObjectHeaderStart> streamObjectHeader)
        This method is used to parse the actual 16bit or 32bit stream header.
        Parameters:
        byteArray - Specify the Byte array.
        startIndex - Specify the start position.
        streamObjectHeader - Specify the out value for the parse result.
        Returns:
        Return true if success, otherwise returns false.