Class Parser.DefaultNodeVisitor
java.lang.Object
org.springframework.shell.command.parser.AbstractNodeVisitor
org.springframework.shell.command.parser.Parser.DefaultNodeVisitor
- All Implemented Interfaces:
NodeVisitor
- Enclosing interface:
- Parser
Default implementation of a
NodeVisitor
.-
Method Summary
Modifier and TypeMethodDescriptionprotected Parser.ParseResult
Called after all nodes has been visited to build results.protected void
Called whenCommandArgumentNode
is entered.protected void
Called whenCommandNode
is entered.protected void
Called whenDirectiveNode
is entered.protected void
Called whenOptionArgumentNode
is entered.protected void
onEnterOptionNode
(OptionNode node) Called whenOptionNode
is entered.protected void
Called whenCommandNode
for root is entered.protected void
Called whenCommandArgumentNode
is exited.protected void
onExitCommandNode
(CommandNode node) Called whenCommandNode
is exited.protected void
Called whenDirectiveNode
is exited.protected void
Called whenOptionArgumentNode
is exited.protected void
onExitOptionNode
(OptionNode node) Called whenOptionNode
is exited.protected void
Called whenCommandNode
for root is exited.Methods inherited from class org.springframework.shell.command.parser.AbstractNodeVisitor
visit
-
Method Details
-
buildResult
Description copied from class:AbstractNodeVisitor
Called after all nodes has been visited to build results.- Specified by:
buildResult
in classAbstractNodeVisitor
- Returns:
- the results from this visit operation
-
onEnterDirectiveNode
Description copied from class:AbstractNodeVisitor
Called whenDirectiveNode
is entered. When node is fully visited,AbstractNodeVisitor.onExitDirectiveNode(DirectiveNode)
is called.- Specified by:
onEnterDirectiveNode
in classAbstractNodeVisitor
- Parameters:
node
- the option node- See Also:
-
onExitDirectiveNode
Description copied from class:AbstractNodeVisitor
Called whenDirectiveNode
is exited.- Specified by:
onExitDirectiveNode
in classAbstractNodeVisitor
- Parameters:
node
- the option node- See Also:
-
onEnterRootCommandNode
Description copied from class:AbstractNodeVisitor
Called whenCommandNode
for root is entered. When node is fully visited,AbstractNodeVisitor.onExitRootCommandNode(CommandNode)
is called.- Specified by:
onEnterRootCommandNode
in classAbstractNodeVisitor
- Parameters:
node
- the command node- See Also:
-
onExitRootCommandNode
Description copied from class:AbstractNodeVisitor
Called whenCommandNode
for root is exited.- Specified by:
onExitRootCommandNode
in classAbstractNodeVisitor
- Parameters:
node
- the command node- See Also:
-
onEnterCommandNode
Description copied from class:AbstractNodeVisitor
Called whenCommandNode
is entered. When node is fully visited,AbstractNodeVisitor.onExitCommandNode(CommandNode)
is called.- Specified by:
onEnterCommandNode
in classAbstractNodeVisitor
- Parameters:
node
- the command node- See Also:
-
onExitCommandNode
Description copied from class:AbstractNodeVisitor
Called whenCommandNode
is exited.- Specified by:
onExitCommandNode
in classAbstractNodeVisitor
- Parameters:
node
- the command node- See Also:
-
onEnterOptionNode
Description copied from class:AbstractNodeVisitor
Called whenOptionNode
is entered. When node is fully visited,AbstractNodeVisitor.onExitOptionNode(OptionNode)
is called.- Specified by:
onEnterOptionNode
in classAbstractNodeVisitor
- Parameters:
node
- the option node- See Also:
-
onExitOptionNode
Description copied from class:AbstractNodeVisitor
Called whenOptionNode
is exited.- Specified by:
onExitOptionNode
in classAbstractNodeVisitor
- Parameters:
node
- the option node- See Also:
-
onEnterCommandArgumentNode
Description copied from class:AbstractNodeVisitor
Called whenCommandArgumentNode
is entered. When node is fully visited,AbstractNodeVisitor.onExitCommandArgumentNode(CommandArgumentNode)
is called.- Specified by:
onEnterCommandArgumentNode
in classAbstractNodeVisitor
- Parameters:
node
- the command argument node- See Also:
-
onExitCommandArgumentNode
Description copied from class:AbstractNodeVisitor
Called whenCommandArgumentNode
is exited.- Specified by:
onExitCommandArgumentNode
in classAbstractNodeVisitor
- Parameters:
node
- the command argument node- See Also:
-
onEnterOptionArgumentNode
Description copied from class:AbstractNodeVisitor
Called whenOptionArgumentNode
is entered. When node is fully visited,AbstractNodeVisitor.onExitOptionArgumentNode(OptionArgumentNode)
is called.- Specified by:
onEnterOptionArgumentNode
in classAbstractNodeVisitor
- Parameters:
node
- the option argument node- See Also:
-
onExitOptionArgumentNode
Description copied from class:AbstractNodeVisitor
Called whenOptionArgumentNode
is exited.- Specified by:
onExitOptionArgumentNode
in classAbstractNodeVisitor
- Parameters:
node
- the command argument node- See Also:
-