Class EncodingWriter

All Implemented Interfaces:
Closeable, Flushable, Appendable, AutoCloseable

public class EncodingWriter extends MetadataWriter<Encoding>
Encoding header writer.
Author:
Jerome Louvel
  • Constructor Details

    • EncodingWriter

      public EncodingWriter()
  • Method Details

    • write

      public static String write(List<Encoding> encodings)
      Writes a list of encodings.
      Parameters:
      encodings - The encodings to write.
      Returns:
      This writer.
    • canWrite

      protected boolean canWrite(Encoding encoding)
      Description copied from class: HeaderWriter
      Indicates if the value can be written to the header. Useful to prevent the writing of Encoding.IDENTITY constants for example. By default it returns true for non null values.
      Overrides:
      canWrite in class HeaderWriter<Encoding>
      Parameters:
      encoding - The value to add.
      Returns:
      True if the value can be added.