Class IdentityEncoder

  • All Implemented Interfaces:

    public class IdentityEncoder
    extends AbstractEncoder
    Does nothing other than convert the char array to a byte array using the specified encoding.
    • Field Detail

      • charset

        protected Charset charset
    • Constructor Detail

      • IdentityEncoder

        public IdentityEncoder()
      • IdentityEncoder

        public IdentityEncoder​(Charset charset)
    • Method Detail

      • encode

        public BytesRef encode​(char[] buffer,
                               int offset,
                               int length)
        Description copied from interface: PayloadEncoder
        Convert a char array to a BytesRef
        encoded BytesRef