Allow for use of named suggestion providers in @Flag annotated command method parameters, add methods to FlagContext to work with flag values as optionals

This commit is contained in:
jmp 2020-11-01 13:38:08 -08:00 committed by Alexander Söderberg
parent 6d0301d9dd
commit fc1a613463
10 changed files with 104 additions and 30 deletions

View file

@ -23,6 +23,8 @@
//
package cloud.commandframework.annotations;
import org.checkerframework.checker.nullness.qual.NonNull;
import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
@ -40,13 +42,13 @@ public @interface CommandMethod {
*
* @return Command syntax
*/
String value();
@NonNull String value();
/**
* The required sender
*
* @return Required sender
*/
Class<?> requiredSender() default Object.class;
@NonNull Class<?> requiredSender() default Object.class;
}