Enum Class LineDelimiter

java.lang.Object
java.lang.Enum<LineDelimiter>
de.siegmar.fastcsv.writer.LineDelimiter
All Implemented Interfaces:
Serializable, Comparable<LineDelimiter>, Constable

public enum LineDelimiter extends Enum<LineDelimiter>
Enumeration for different line delimiters (LF, CR, CRLF, platform default).
  • Enum Constant Details

  • Method Details

    • values

      public static LineDelimiter[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static LineDelimiter valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • of

      public static LineDelimiter of(String str)

      Maps a line delimiter string to the corresponding enum constant.

      Accepted values are "\r\n" (CRLF), "\n" (LF) and "\r" (CR). The PLATFORM constant is never returned by this method.

      Parameters:
      str - the line delimiter string to look up.
      Returns:
      the matching enum constant.
      Throws:
      IllegalArgumentException - if the string is not a known line delimiter.
    • toString

      public String toString()
      Overrides:
      toString in class Enum<LineDelimiter>