Enum Class LineEnding

java.lang.Object
java.lang.Enum<LineEnding>
jfx.incubator.scene.control.richtext.LineEnding
All Implemented Interfaces:
Serializable, Comparable<LineEnding>, Constable

public enum LineEnding extends Enum<LineEnding>
Specifies line separator (line ending) characters.
Since:
26
  • Enum Constant Details

    • CR

      public static final LineEnding CR
      Legacy Mac OS line ending, ASCII CR (0x0d).
    • CRLF

      public static final LineEnding CRLF
      Windows line ending, sequence of CR/LF (0x0d 0x0a).
    • LF

      public static final LineEnding LF
      macOS/Unix line ending, ASCII LF (0x0a).
  • Method Details

    • values

      public static LineEnding[] 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 LineEnding 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
    • getText

      public String getText()
      Returns the line ending as a String.
      Returns:
      the line ending string
    • system

      public static LineEnding system()
      Returns the LineEnding based on the value of system line separator string System.lineSeparator().
      Returns:
      the system default line ending