Enum Class Rail.Orientation

java.lang.Object
java.lang.Enum<Rail.Orientation>
cn.nukkit.utils.Rail.Orientation
All Implemented Interfaces:
Serializable, Comparable<Rail.Orientation>, Constable
Enclosing class:
Rail

public static enum Rail.Orientation extends Enum<Rail.Orientation>
  • Enum Constant Details

  • Method Details

    • values

      public static Rail.Orientation[] 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 Rail.Orientation 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
    • byMetadata

      public static Rail.Orientation byMetadata(int meta)
    • straight

      public static Rail.Orientation straight(BlockFace face)
    • ascending

      public static Rail.Orientation ascending(BlockFace face)
    • curved

      public static Rail.Orientation curved(BlockFace f1, BlockFace f2)
    • straightOrCurved

      public static Rail.Orientation straightOrCurved(BlockFace f1, BlockFace f2)
    • metadata

      public int metadata()
    • hasConnectingDirections

      public boolean hasConnectingDirections(BlockFace... faces)
    • hasConnectingDirections

      public boolean hasConnectingDirections(Collection<BlockFace> faces)
    • connectingDirections

      public List<BlockFace> connectingDirections()
    • ascendingDirection

      public Optional<BlockFace> ascendingDirection()
    • isStraight

      public boolean isStraight()
    • isAscending

      public boolean isAscending()
    • isCurved

      public boolean isCurved()