Package swingtree

Interface UIEnum<E extends Enum<E>>

Type Parameters:
E - The enum type.
All Known Implementing Classes:
UI.Active, UI.Align, UI.Alignment, UI.Axis, UI.ComponentArea, UI.ComponentBoundary, UI.ComponentOrientation, UI.Corner, UI.Cursor, UI.Cycle, UI.Edge, UI.FontStyle, UI.GradientType, UI.HorizontalAlignment, UI.Layer, UI.ListData, UI.LookAndFeel, UI.MapData, UI.NoiseType, UI.OnWindowClose, UI.OverflowPolicy, UI.Placement, UI.Side, UI.Span, UI.VerticalAlignment

@Immutable public interface UIEnum<E extends Enum<E>>
A set of extension methods for various SwingTree enums.
  • Method Summary

    Modifier and Type
    Method
    Description
    default boolean
    isNoneOf(E first, E second)
    Checks if this enum value is none of the 2 given values.
    default boolean
    isNoneOf(E first, E... rest)
    Checks if this enum value is none of the given values.
    default boolean
    isNoneOf(Iterable<E> values)
    Checks if this enum value is none of the given iterable values.
    default boolean
    isOneOf(E first, E second)
    Checks if this enum value is one of the 2 given values.
    default boolean
    isOneOf(E first, E... rest)
    Checks if this enum value is one of the given values.
    default boolean
    isOneOf(Iterable<E> values)
    Checks if this enum value is one of the given iterable values.
  • Method Details

    • isOneOf

      default boolean isOneOf(E first, E... rest)
      Checks if this enum value is one of the given values.
      Parameters:
      first - The first enum value to compare to.
      rest - The rest of the enum values to compare to.
      Returns:
      True if this enum value is one of the given values.
    • isOneOf

      default boolean isOneOf(E first, E second)
      Checks if this enum value is one of the 2 given values.
      Parameters:
      first - The first enum value to compare to.
      second - The second enum value to compare to.
      Returns:
      True if this enum value is one of the given values.
    • isNoneOf

      default boolean isNoneOf(E first, E... rest)
      Checks if this enum value is none of the given values.
      Parameters:
      first - The first enum value to compare to.
      rest - The rest of the enum values to compare to.
      Returns:
      True if this enum value is none of the given values.
    • isNoneOf

      default boolean isNoneOf(E first, E second)
      Checks if this enum value is none of the 2 given values.
      Parameters:
      first - The first enum value to compare to.
      second - The second enum value to compare to.
      Returns:
      True if this enum value is none of the given values.
    • isOneOf

      default boolean isOneOf(Iterable<E> values)
      Checks if this enum value is one of the given iterable values.
      Parameters:
      values - The iterable values to compare to.
      Returns:
      True if this enum value is one of the given values.
    • isNoneOf

      default boolean isNoneOf(Iterable<E> values)
      Checks if this enum value is none of the given iterable values.
      Parameters:
      values - The iterable values to compare to.
      Returns:
      True if this enum value is none of the given values.