Class Choice4._D<A,​B,​C,​D>

    • Field Detail

      • d

        private final D d
    • Constructor Detail

      • _D

        private _D​(D d)
    • Method Detail

      • match

        public <R> R match​(Fn1<? super A,​? extends R> aFn,
                           Fn1<? super B,​? extends R> bFn,
                           Fn1<? super C,​? extends R> cFn,
                           Fn1<? super D,​? extends R> dFn)
        Description copied from interface: CoProduct4
        Type-safe convergence requiring a match against all potential types.
        Type Parameters:
        R - result type
        Parameters:
        aFn - morphism A -> R
        bFn - morphism B -> R
        cFn - morphism C -> R
        dFn - morphism D -> R
        Returns:
        the result of applying the appropriate morphism from whichever type is represented by this coproduct to R
        See Also:
        CoProduct2.match(Fn1, Fn1)
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object