|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.mmm.util.cli.base.CliParameterContainer
net.sf.mmm.util.cli.base.CliOptionContainer
public class CliOptionContainer
This is a container for a CliOption
together with additional
associated information.
Field Summary | |
---|---|
private CliOption |
option
|
Constructor Summary | |
---|---|
CliOptionContainer(CliOption option,
PojoPropertyAccessorOneArg setter,
PojoPropertyAccessorNonArg getter,
ValueValidator validator)
The constructor. |
Method Summary | |
---|---|
CliContainerStyle |
getContainerStyle(CliStyle cliStyle)
This method gets the style of this parameter. |
protected String |
getName()
This method gets the name of the option or argument . |
CliOption |
getOption()
This method gets the actual CliOption . |
protected Annotation |
getParameterAnnotation()
This method gets the annotation with the metadata of the option or
argument . |
boolean |
isTrigger()
This method determines if the option is a trigger. |
Methods inherited from class net.sf.mmm.util.cli.base.CliParameterContainer |
---|
getGetter, getSetter, getValidator, isArrayMapOrCollection, isArrayMapOrCollection, toString |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private final CliOption option
getOption()
Constructor Detail |
---|
public CliOptionContainer(CliOption option, PojoPropertyAccessorOneArg setter, PojoPropertyAccessorNonArg getter, ValueValidator validator)
option
- is the option
.setter
- is the setter
.getter
- is the getter
.validator
- is the validator
.Method Detail |
---|
protected String getName()
option
or argument
.
getName
in class CliParameterContainer
protected Annotation getParameterAnnotation()
option
or
argument
.
getParameterAnnotation
in class CliParameterContainer
Annotation
.public CliOption getOption()
CliOption
.
CliOption
.public boolean isTrigger()
option
is a trigger.
Trigger means that the type of the setter
is a
primitive boolean and the option is never followed by a value on the
commandline.
true
if trigger, false
otherwise.public CliContainerStyle getContainerStyle(CliStyle cliStyle)
style
of this parameter. If
the style of the parameter-annotation (
CliArgument.containerStyle()
or
CliOption.containerStyle()
) is
CliContainerStyle.DEFAULT
this method will return
CliStyle.containerStyle()
.
getContainerStyle
in class CliParameterContainer
cliStyle
- TODO
style
for this parameter.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |