Class TypeSwitch2<I0,I1,O>
- java.lang.Object
-
- com.g2forge.alexandria.java.type.function.TypeSwitch2<I0,I1,O>
-
- All Implemented Interfaces:
IConsumer
,IConsumer2<I0,I1>
,IFunction<O>
,IFunction2<I0,I1,O>
,IFunctional
,BiConsumer<I0,I1>
,BiFunction<I0,I1,O>
public class TypeSwitch2<I0,I1,O> extends Object implements IFunction2<I0,I1,O>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
TypeSwitch2.ConsumerBuilder<I0,I1>
static class
TypeSwitch2.FunctionBuilder<I0,I1,O>
protected static class
TypeSwitch2.Node<O>
-
Field Summary
Fields Modifier and Type Field Description protected IFunction2<? super I0,? super I1,? extends O>
fallback
protected TypeSwitch2.Node<O>
root
-
Constructor Summary
Constructors Constructor Description TypeSwitch2(IFunction2<? super I0,? super I1,? extends O> fallback, com.g2forge.alexandria.java.type.function.TypedFunction2<I0,I1,O>... functions)
TypeSwitch2(IFunction2<? super I0,? super I1,? extends O> fallback, Collection<? extends ITypedFunction2<?,?,? extends O>> functions)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description O
apply(I0 input0, I1 input1)
protected IFunction2<? super I0,? super I1,? extends O>
getFallback()
protected TypeSwitch2.Node<O>
getRoot()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.util.function.BiFunction
andThen
-
Methods inherited from interface com.g2forge.alexandria.java.function.IConsumer2
andThen
-
Methods inherited from interface com.g2forge.alexandria.java.function.IFunction2
accept, compose0, compose1, compute0, compute1, curry0, curry1, lift0, lift1, noReturn, sync, toConsumer, toFunction, wrap
-
-
-
-
Field Detail
-
fallback
protected final IFunction2<? super I0,? super I1,? extends O> fallback
-
root
protected final TypeSwitch2.Node<O> root
-
-
Constructor Detail
-
TypeSwitch2
public TypeSwitch2(IFunction2<? super I0,? super I1,? extends O> fallback, Collection<? extends ITypedFunction2<?,?,? extends O>> functions)
-
TypeSwitch2
@SafeVarargs public TypeSwitch2(IFunction2<? super I0,? super I1,? extends O> fallback, com.g2forge.alexandria.java.type.function.TypedFunction2<I0,I1,O>... functions)
-
-
Method Detail
-
getFallback
protected IFunction2<? super I0,? super I1,? extends O> getFallback()
-
getRoot
protected TypeSwitch2.Node<O> getRoot()
-
-