Module com.pi4j

Enum Class SpiBus

java.lang.Object
java.lang.Enum<SpiBus>
com.pi4j.io.spi.SpiBus
All Implemented Interfaces:
Serializable, Comparable<SpiBus>, Constable

public enum SpiBus extends Enum<SpiBus>

SpiBus class.

Version:
$Id: $Id
Author:
Robert Savage (http://www.savagehomeautomation.com)
  • Enum Constant Details

    • BUS_0

      public static final SpiBus BUS_0
    • BUS_1

      public static final SpiBus BUS_1
    • BUS_2

      public static final SpiBus BUS_2
    • BUS_3

      public static final SpiBus BUS_3
    • BUS_4

      public static final SpiBus BUS_4
    • BUS_5

      public static final SpiBus BUS_5
    • BUS_6

      public static final SpiBus BUS_6
  • Method Details

    • values

      public static SpiBus[] 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 SpiBus 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
    • getBus

      public int getBus()

      Getter for the field bus.

      Returns:
      a int.
    • getByNumber

      public static SpiBus getByNumber(short busNumber)

      getByNumber.

      Parameters:
      busNumber - a short.
      Returns:
      a SpiBus object.
    • getByNumber

      public static SpiBus getByNumber(int busNumber)

      getByNumber.

      Parameters:
      busNumber - a int.
      Returns:
      a SpiBus object.
    • parse

      public static SpiBus parse(String bus)

      parse.

      Parameters:
      bus - a String object.
      Returns:
      a SpiBus object.