Enum Class LinearLayout.Orientation

java.lang.Object
java.lang.Enum<LinearLayout.Orientation>
xyz.gmitch215.socketmc.screen.layout.LinearLayout.Orientation
All Implemented Interfaces:
Serializable, Comparable<LinearLayout.Orientation>, Constable
Enclosing class:
LinearLayout

public static enum LinearLayout.Orientation extends Enum<LinearLayout.Orientation>
Represents the orientation for a LinearLayout.
  • Enum Constant Details

  • Method Details

    • values

      public static LinearLayout.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 LinearLayout.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
    • setSpacing

      public void setSpacing(@NotNull @NotNull GridLayout layout, int spacing)
      Sets the spacing of the layout.
      Parameters:
      layout - The layout to set the spacing of
      spacing - The spacing to set
    • addElement

      @NotNull public <T extends LayoutElement> T addElement(@NotNull @NotNull GridLayout layout, @NotNull T element, int index, @NotNull @NotNull LayoutSettings layoutSettings) throws IllegalArgumentException
      Adds an element to the layout.
      Type Parameters:
      T - The type of the element
      Parameters:
      layout - The layout to add the element to
      element - The element to add
      index - The index to add the element at
      layoutSettings - The settings to apply to the element
      Returns:
      The element that was added
      Throws:
      IllegalArgumentException - if the layout, element, or settings are null