Uses of Class
com.clumd.projects.java_common_utils.arg_parser.Argument.ArgumentBuilder
Packages that use Argument.ArgumentBuilder
-
Uses of Argument.ArgumentBuilder in com.clumd.projects.java_common_utils.arg_parser
Methods in com.clumd.projects.java_common_utils.arg_parser that return Argument.ArgumentBuilderModifier and TypeMethodDescriptionArgument.ArgumentBuilder.argumentResult(T argumentResult) If this argument needs a value, then this should be the fully validated and parsed output of that value.static <T> Argument.ArgumentBuilder<T>Argument.builder()<E extends Exception>
Argument.ArgumentBuilder<T>Argument.ArgumentBuilder.conversionFunction(FunctionPotentialException<String, T, E> functionWhichMayThrowException) This constructor is used to override the conversion function in order to wrap the call to theFunction.apply(Object)such that the implementing user can use checked exceptions if they want, without it causing compile time issues.Argument.ArgumentBuilder.defaultValue(T toValue) Used to set the default value, and also mark that the default value has been set.Argument.ArgumentBuilder.defaultValueSet(boolean defaultValueSet) Used to track if a default value has been set for this argument to be used if no CLI value is found.Argument.ArgumentBuilder.description(String description) Used to describe the purpose of this Argument and how it should be used.Argument.ArgumentBuilder.hasValue(boolean toValue) This is used to set the hasValue of this argument, it is only required as an override to the default constructor to allow the conversionFunction to trigger a change of state when a conversionFunction is provided.Argument.ArgumentBuilder.isMandatory(boolean isMandatory) Used to indicate if this argument is mandatory and MUST be provided for the utilising code to function.Argument.ArgumentBuilder.longOptions(Set<String> longOptions) Used to contain all the word alias' to indicate this optionArgument.ArgumentBuilder.mustBeUsedWith(Set<String> mustBeUsedWith) Used to denote other CLI Arguments (by reference to theirArgument.uniqueId) which MUST be present if, and only if, this Argument is found on the CLI.Argument.ArgumentBuilder.mustNotBeUsedWith(Set<String> mustNotBeUsedWith) Used to denote other CLI Arguments (by reference to theirArgument.uniqueId) which MUST NOT be used in conjunction with this one if, and only if, this Argument is found on the CLI.Argument.ArgumentBuilder.shortOptions(Set<Character> shortOptions) Used to contain all the single character alias' to indicate this optionArgument.ArgumentBuilder.shouldShortCircuit(boolean shouldShortCircuit) Used to tell a parser that if this argument is detected on the CLI at all, it should ALWAYS be returnable to the caller with all present short circuit args.This is used to set the uniqueId of this argument, it is only required as an override to the default constructor to have the value available to the exception strings in theFunctionPotentialExceptionmethods below<E extends Exception>
Argument.ArgumentBuilder<T>Argument.ArgumentBuilder.validationFunction(FunctionPotentialException<T, Boolean, E> functionWhichMayThrowException) This constructor is used to override the value validation function in order to wrap the call to theFunction.apply(Object)such that the implementing user can use checked exceptions if they want, without it causing compile time issues.Argument.ArgumentBuilder.valueIsOptional(boolean valueIsOptional) Used to indicate if the value to this argument can be optional, defaults to false.