Package adams.core.option
Class XhtmlProducer.ActorOptionTraverser
- java.lang.Object
-
- adams.core.option.XhtmlProducer.ActorOptionTraverser
-
- All Implemented Interfaces:
OptionTraverser
- Enclosing class:
- XhtmlProducer
public static class XhtmlProducer.ActorOptionTraverser extends Object implements OptionTraverser
-
-
Field Summary
Fields Modifier and Type Field Description protected UnorderedList
m_Details
for adding the latex code.protected boolean
m_OutputDefaultValues
whether to output default values.protected boolean
m_OutputVariableValues
whether to output variable values.
-
Constructor Summary
Constructors Constructor Description ActorOptionTraverser(UnorderedList details, boolean varValues, boolean defValues)
Initializes the traverser.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
addDescription(Table parent, AbstractOption option)
Adds the description of the option as row.protected Table
addStaticInfo(AbstractOption option)
Adds static information, like property, command-line flag and description.boolean
canHandle(AbstractOption option)
Returns whether the traverser is allowed to "handle" this option.boolean
canRecurse(Class cls)
Returns whether the traverser can recurse the specified class (base class from a ClassOption).boolean
canRecurse(Object obj)
Returns whether the traverser can recurse the specified object.void
handleArgumentOption(AbstractArgumentOption option, OptionTraversalPath path)
Handles the encountered argument option.void
handleBooleanOption(BooleanOption option, OptionTraversalPath path)
Handles the encountered boolean option.void
handleClassOption(ClassOption option, OptionTraversalPath path)
Handles the encountered class option.
-
-
-
Field Detail
-
m_Details
protected UnorderedList m_Details
for adding the latex code.
-
m_OutputVariableValues
protected boolean m_OutputVariableValues
whether to output variable values.
-
m_OutputDefaultValues
protected boolean m_OutputDefaultValues
whether to output default values.
-
-
Constructor Detail
-
ActorOptionTraverser
public ActorOptionTraverser(UnorderedList details, boolean varValues, boolean defValues)
Initializes the traverser.- Parameters:
details
- for adding the latex codevarValues
- whether to output variable valuesdefValues
- whether to output default values
-
-
Method Detail
-
addDescription
protected void addDescription(Table parent, AbstractOption option)
Adds the description of the option as row.- Parameters:
parent
- the table to add tooption
- the option to use
-
addStaticInfo
protected Table addStaticInfo(AbstractOption option)
Adds static information, like property, command-line flag and description.- Parameters:
option
- the option to get the static information from
-
handleBooleanOption
public void handleBooleanOption(BooleanOption option, OptionTraversalPath path)
Description copied from interface:OptionTraverser
Handles the encountered boolean option.- Specified by:
handleBooleanOption
in interfaceOptionTraverser
- Parameters:
option
- the option to handlepath
- the property path so far
-
handleClassOption
public void handleClassOption(ClassOption option, OptionTraversalPath path)
Description copied from interface:OptionTraverser
Handles the encountered class option. Precedence over argument option.- Specified by:
handleClassOption
in interfaceOptionTraverser
- Parameters:
option
- the option to handlepath
- the property path so far
-
handleArgumentOption
public void handleArgumentOption(AbstractArgumentOption option, OptionTraversalPath path)
Description copied from interface:OptionTraverser
Handles the encountered argument option.- Specified by:
handleArgumentOption
in interfaceOptionTraverser
- Parameters:
option
- the option to handlepath
- the property path so far
-
canHandle
public boolean canHandle(AbstractOption option)
Description copied from interface:OptionTraverser
Returns whether the traverser is allowed to "handle" this option.- Specified by:
canHandle
in interfaceOptionTraverser
- Parameters:
option
- the option to check whether it can be handled- Returns:
- true if handling via
OptionTraverser.handleArgumentOption(AbstractArgumentOption, OptionTraversalPath)
,OptionTraverser.handleClassOption(ClassOption, OptionTraversalPath)
orOptionTraverser.handleBooleanOption(BooleanOption, OptionTraversalPath)
is allowed
-
canRecurse
public boolean canRecurse(Class cls)
Description copied from interface:OptionTraverser
Returns whether the traverser can recurse the specified class (base class from a ClassOption).- Specified by:
canRecurse
in interfaceOptionTraverser
- Parameters:
cls
- the class to determine for whether recursing is possible or not- Returns:
- true if to traverse the options recursively
-
canRecurse
public boolean canRecurse(Object obj)
Description copied from interface:OptionTraverser
Returns whether the traverser can recurse the specified object.- Specified by:
canRecurse
in interfaceOptionTraverser
- Parameters:
obj
- the Object to determine for whether recursing is possible or not- Returns:
- true if to traverse the options recursively
-
-