Class LambdaSupport


  • @API(status=INTERNAL)
    public class LambdaSupport
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <T> boolean areEqual​(T l1, T l2)
      This method is used in Object.equals(Object) implementations of Arbitrary types to allow memoization of generators.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • areEqual

        public static <T> boolean areEqual​(T l1,
                                           T l2)
        This method is used in Object.equals(Object) implementations of Arbitrary types to allow memoization of generators.

        Comparing two lambdas by their implementation class works if they don't access an enclosing object's state. When in doubt, fail comparison.