Class ArgumentPair.ArgumentPairIntermediaryBuilder<C,U,V>
java.lang.Object
cloud.commandframework.arguments.compound.ArgumentPair.ArgumentPairIntermediaryBuilder<C,U,V>
- Enclosing class:
- ArgumentPair<C,
U, V, O>
@API(status=STABLE)
public static final class ArgumentPair.ArgumentPairIntermediaryBuilder<C,U,V>
extends Object
-
Method Summary
Modifier and TypeMethodDescriptionsimple()Create a simple argument pair that maps to a pair<O> @NonNull ArgumentPair<C,U, V, O> withMapper(@NonNull io.leangen.geantyref.TypeToken<O> clazz, @NonNull BiFunction<@NonNull C, @NonNull Pair<@NonNull U, @NonNull V>, @NonNull O> mapper) Create an argument pair that maps to a specific type<O> @NonNull ArgumentPair<@NonNull C,@NonNull U, @NonNull V, @NonNull O> withMapper(@NonNull Class<O> clazz, @NonNull BiFunction<@NonNull C, @NonNull Pair<@NonNull U, @NonNull V>, @NonNull O> mapper) Create an argument pair that maps to a specific type
-
Method Details
-
simple
public @NonNull ArgumentPair<@NonNull C,@NonNull U, simple()@NonNull V, @NonNull Pair<@NonNull U, @NonNull V>> Create a simple argument pair that maps to a pair- Returns:
- Argument pair
-
withMapper
public <O> @NonNull ArgumentPair<C,U, withMapperV, O> (@NonNull io.leangen.geantyref.TypeToken<O> clazz, @NonNull BiFunction<@NonNull C, @NonNull Pair<@NonNull U, @NonNull V>, @NonNull O> mapper) Create an argument pair that maps to a specific type- Type Parameters:
O- Output type- Parameters:
clazz- Output classmapper- Output mapper- Returns:
- Created pair
-
withMapper
public <O> @NonNull ArgumentPair<@NonNull C,@NonNull U, withMapper@NonNull V, @NonNull O> (@NonNull Class<O> clazz, @NonNull BiFunction<@NonNull C, @NonNull Pair<@NonNull U, @NonNull V>, @NonNull O> mapper) Create an argument pair that maps to a specific type- Type Parameters:
O- Output type- Parameters:
clazz- Output classmapper- Output mapper- Returns:
- Created pair
-