com.neeve.cli.annotations
Annotation Type RemainingArgs


@Retention(value=RUNTIME)
@Target(value={FIELD,PARAMETER})
public @interface RemainingArgs

Can be placed on at most one String[] or String field to catch any remaining arguments after any defined optional arguments. This is useful for command that have an unspecified number of trailing arguments.


Required Element Summary
 String description
          A brief description desribing what should be supplied as arguments.
 String name
          A short name of for the arguments.
 
Optional Element Summary
 String defaultValue
          The argument's default value.
 String displayName
          Returns a display name for the arguments.
 boolean required
          It is illegal to posistion a required argument after an optional one.
 boolean requoteForSingleString
          Whether to requote and escape strings when applying remaining args to a single string value.
 

Element Detail

name

public abstract String name
A short name of for the arguments.

This is a short name that should contain no spaces.

Returns:
The short name of the argument

description

public abstract String description
A brief description desribing what should be supplied as arguments.

Returns:
Description for the argument

displayName

public abstract String displayName
Returns a display name for the arguments.

This value can be used by user interfaces in place of the actual argument name. When this value is omitted, the name() should be used.

Returns:
A short, friendly display name for the argument.
Default:
""

defaultValue

public abstract String defaultValue
The argument's default value.

Returns:
The argument's default value
Default:
""

required

public abstract boolean required
It is illegal to posistion a required argument after an optional one.

Returns:
Whether or not the argument is required
Default:
true

requoteForSingleString

public abstract boolean requoteForSingleString
Whether to requote and escape strings when applying remaining args to a single string value.

Returns:
Whether or not to requote string arguments.
Default:
false


Copyright © 2016 Neeve Research, LLC. All Rights Reserved.