Class Encoders

    • Constructor Detail

      • Encoders

        protected Encoders​(CodecType type)
    • Method Detail

      • getCodecType

        public int getCodecType()
        Description copied from interface: AttributeEncoder

        Return the unique code for the type that this encoder encodes. This must be the ordinal() of the corresponding CodecType enum value.

        This is only used on Encoders for element attributes, because attributes need to be read in with no intervention, so this ID is used to look up the correct decoder. For element bodies, the handler has the chance to instantiate the correct decoder before parsing, so no type code is needed.

        Specified by:
        getCodecType in interface AttributeEncoder
      • forString

        public static AttributeEncoder forString​(java.lang.String s,
                                                 boolean escape)
      • forSignature

        public static AttributeEncoder forSignature​(java.lang.Class[] array)