Enum HeaderType

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Comparable<HeaderType>

    public enum HeaderType
    extends java.lang.Enum<HeaderType>
    Java mirror of the native aws_event_stream_header_value_type enum, specifying properties of the type of a header's value
    • Method Detail

      • values

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

        public static HeaderType valueOf​(java.lang.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:
        java.lang.IllegalArgumentException - if this enum type has no constant with the specified name
        java.lang.NullPointerException - if the argument is null
      • getWireBytesOverhead

        public int getWireBytesOverhead()
        Returns:
        additional bytes needed to serialize the header's value, beyond the value's data itself
      • getEnumIntValue

        public int getEnumIntValue()
        Returns:
        the native integer value associated with this Java enum value
      • isVariableLength

        public boolean isVariableLength()
        Returns:
        true if encoding this type requires a variable number of bytes, false if a fixed number of bytes
      • getValueFromInt

        public static HeaderType getValueFromInt​(int intValue)
        Creates a Java header type enum from an associated native integer value
        Parameters:
        intValue - native integer value
        Returns:
        a new Java header type value