java.lang.Object
dev.sympho.modular_commands.utils.parse.UrlParser.ChoiceBase<T,P>
dev.sympho.modular_commands.utils.parse.FunctorUrlParser.ChoiceBase<T,FunctorUrlParser<T>>
dev.sympho.modular_commands.utils.parse.FunctorUrlParser.Choice<T>
- Type Parameters:
T- The parsed argument type.
- All Implemented Interfaces:
ParserFunction<String,,T> FunctorUrlParser<T>,UrlParser<T>,BiFunction<CommandContext,String, Mono<T>>
- Enclosing interface:
- FunctorUrlParser<T extends @NonNull Object>
public static class FunctorUrlParser.Choice<T extends @NonNull Object>
extends FunctorUrlParser.ChoiceBase<T,FunctorUrlParser<T>>
Parser that supports multiple URL types by delegating to one of a list of parsers. Note
that this includes
compatibility checks.- Since:
- 1.0
- API Note:
- This is a convenience subtype of
ChoiceBasewith the second parameter already set.
-
Nested Class Summary
Nested classes/interfaces inherited from interface dev.sympho.modular_commands.utils.parse.FunctorUrlParser
FunctorUrlParser.Choice<T extends @NonNull Object>, FunctorUrlParser.ChoiceBase<T extends @NonNull Object,P extends FunctorUrlParser<T>>, FunctorUrlParser.PostParser<I extends @NonNull Object, T extends @NonNull Object, P1 extends @NonNull FunctorUrlParser<I>, P2 extends @NonNull Parsers.Functor<I, T>> Nested classes/interfaces inherited from interface dev.sympho.modular_commands.utils.parse.UrlParser
UrlParser.Choice<T extends @NonNull Object>, UrlParser.ChoiceBase<T extends @NonNull Object,P extends UrlParser<T>>, UrlParser.PostParser<I extends @NonNull Object, T extends @NonNull Object, P1 extends @NonNull UrlParser<I>, P2 extends @NonNull ParserFunction<I, T>> -
Constructor Summary
Constructors -
Method Summary
Methods inherited from class dev.sympho.modular_commands.utils.parse.FunctorUrlParser.ChoiceBase
parseMethods inherited from class dev.sympho.modular_commands.utils.parse.UrlParser.ChoiceBase
getParser, parse, supportsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface java.util.function.BiFunction
andThenMethods inherited from interface dev.sympho.modular_commands.utils.parse.FunctorUrlParser
parse, thenMethods inherited from interface dev.sympho.modular_commands.api.command.parameter.parse.ParserFunction
apply
-
Constructor Details
-
Choice
Creates a new instance.- Parameters:
parserMapper- The function to use to determine which parser to delegate to for a given URL.
-