Class TypeSwitch1.FunctionBuilder<I,O>
- java.lang.Object
-
- com.g2forge.alexandria.java.type.function.TypeSwitch1.FunctionBuilder<I,O>
-
- Enclosing class:
- TypeSwitch1<I,O>
public static class TypeSwitch1.FunctionBuilder<I,O> extends Object
-
-
Field Summary
Fields Modifier and Type Field Description protected IFunction1<? super I,? extends O>
fallback
protected Collection<com.g2forge.alexandria.java.type.function.TypedFunction1<?,O>>
functions
-
Constructor Summary
Constructors Constructor Description FunctionBuilder()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <T> TypeSwitch1.FunctionBuilder<I,O>
add(Class<T> type, IConsumer1<? super T> consumer, O output)
<T> TypeSwitch1.FunctionBuilder<I,O>
add(Class<T> type, IFunction1<? super T,? extends O> function)
IFunction1<I,O>
build()
TypeSwitch1.FunctionBuilder<I,O>
fallback(IFunction1<? super I,? extends O> function)
TypeSwitch1.FunctionBuilder<I,O>
with(IConsumer1<? super TypeSwitch1.FunctionBuilder<I,O>> consumer)
-
-
-
Field Detail
-
functions
protected final Collection<com.g2forge.alexandria.java.type.function.TypedFunction1<?,O>> functions
-
fallback
protected IFunction1<? super I,? extends O> fallback
-
-
Method Detail
-
add
public <T> TypeSwitch1.FunctionBuilder<I,O> add(Class<T> type, IConsumer1<? super T> consumer, O output)
-
add
public <T> TypeSwitch1.FunctionBuilder<I,O> add(Class<T> type, IFunction1<? super T,? extends O> function)
-
build
public IFunction1<I,O> build()
-
fallback
public TypeSwitch1.FunctionBuilder<I,O> fallback(IFunction1<? super I,? extends O> function)
-
with
public TypeSwitch1.FunctionBuilder<I,O> with(IConsumer1<? super TypeSwitch1.FunctionBuilder<I,O>> consumer)
-
-