java.lang.Object
dk.cloudcreate.essentials.shared.functional.tuple.Empty
All Implemented Interfaces:
Tuple<Empty>, Serializable

public final class Empty extends Object implements Tuple<Empty>
Represents a Tuple with zero elements
See Also:
  • Field Details

    • INSTANCE

      public static final Empty INSTANCE
      The shared single instance of the Empty tuple
  • Method Details

    • instance

      public static Empty instance()
      The shared single instance of the Empty tuple
      Returns:
      the shared single instance of the Empty tuple
    • arity

      public int arity()
      Description copied from interface: Tuple
      Number of arguments/elements in the Tuple
      Specified by:
      arity in interface Tuple<Empty>
      Returns:
      Number of arguments/elements in the Tuple
    • toList

      public List<?> toList()
      Description copied from interface: Tuple
      Convert the Tuple to a list
      Specified by:
      toList in interface Tuple<Empty>
      Returns:
      list of all Tuple elements
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object