Class DeltaTriple<T>

All Implemented Interfaces:
DebugDumpable, Foreachable<T>

public class DeltaTriple<T> extends Object implements DebugDumpable, Foreachable<T>
Utility class for keeping things in three: plus, zero and minus.
  • Constructor Details

    • DeltaTriple

      public DeltaTriple()
    • DeltaTriple

      public DeltaTriple(Supplier<T> initializer)
  • Method Details

    • getPlus

      public T getPlus()
    • setPlus

      public void setPlus(T plus)
    • getZero

      public T getZero()
    • setZero

      public void setZero(T zero)
    • getMinus

      public T getMinus()
    • setMinus

      public void setMinus(T minus)
    • get

      public T get(PlusMinusZero mode)
    • foreach

      public void foreach(Processor<T> processor)
      Description copied from interface: Foreachable
      Will call processor for every element in the instance. This is NOT recursive. E.g. in case of collection of collections the processor will NOT be called for elements of the inner collections. If you need recursion please have a look at Visitor.
      Specified by:
      foreach in interface Foreachable<T>
    • debugDump

      public String debugDump(int indent)
      Specified by:
      debugDump in interface DebugDumpable
    • debugDumpNoTitle

      public String debugDumpNoTitle(StringBuilder sb, int indent)
    • hashCode

      public int hashCode()
      hashCode in class Object
    • equals

      public boolean equals(Object obj)
      equals in class Object
    • toString

      public String toString()
      toString in class Object