if (arg.canAppearNext(ctx)) {
if (arg.getIndex() >= 0) {
CommandLineCompleter valCompl = arg.getValueCompleter();
if (valCompl != null) {
final String value = chunk == null ? "" : chunk;
valCompl.complete(ctx, value, value.length(), candidates);
}
} else {
String argFullName = arg.getFullName();
if (chunk == null) {
if (arg.isValueRequired()) {