java.lang.Object
java.lang.Enum<Parity>
org.refcodes.serial.alt.tty.Parity
All Implemented Interfaces:
Serializable, Comparable<Parity>, java.lang.constant.Constable

public enum Parity extends Enum<Parity>
The Parity as of "https://en.wikipedia.org/wiki/Serial_port#Parity"
  • Nested Class Summary

    Nested classes/interfaces inherited from class java.lang.Enum

    Enum.EnumDesc<E extends Enum<E>>
  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    The underlying system's implementation or other implementation specific parity is used.
    "Even (E) means that parity bit is set so that the number of "logical ones" must be even."
    "Mark (M) parity means that the parity bit is always set to the mark signal condition (logical 1)."
    "None (N) means that no parity bit is sent at all."
    "Odd (O) means that parity bit is set so that the number of "logical ones" must be odd."
    "Space (S) parity always sends the parity bit in the space signal condition (logical 0)."
  • Method Summary

    Modifier and Type
    Method
    Description
    static Parity
    Returns the enum constant of this type with the specified name.
    static Parity[]
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • AUTO

      public static final Parity AUTO
      The underlying system's implementation or other implementation specific parity is used.
    • NONE

      public static final Parity NONE
      "None (N) means that no parity bit is sent at all."
    • ODD

      public static final Parity ODD
      "Odd (O) means that parity bit is set so that the number of "logical ones" must be odd."
    • EVEN

      public static final Parity EVEN
      "Even (E) means that parity bit is set so that the number of "logical ones" must be even."
    • MARK

      public static final Parity MARK
      "Mark (M) parity means that the parity bit is always set to the mark signal condition (logical 1)."
    • SPACE

      public static final Parity SPACE
      "Space (S) parity always sends the parity bit in the space signal condition (logical 0)."
  • Method Details

    • values

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

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