Class Operators.IdentityCons<X,Y>

java.lang.Object
eu.bandm.tools.util.Operators.IdentityCons<X,Y>
All Implemented Interfaces:
Operators.Cons<X,Y>
Enclosing class:
Operators

static class Operators.IdentityCons<X,Y> extends Object implements Operators.Cons<X,Y>
  • Constructor Details

    • IdentityCons

      IdentityCons()
  • Method Details

    • consume

      public Y consume(X x, Y y)
      Description copied from interface: Operators.Cons
      Compute a post-state from an input element and a pre-state. Computation should be stateless and thread-safe, i.e., f.consume(x, s) for a given fixed function object f, input element x and state s should not vary unless the observable state of x or s varies.
      Specified by:
      consume in interface Operators.Cons<X,Y>
      Parameters:
      x - an input element.
      y - a pre-state.
      Returns:
      a post-state.
    • toString

      public String toString()
      Overrides:
      toString in class Object