- Type Parameters:
R
- the return type of this visitor's methods. UseVoid
for visitors that do not need to return results.P
- the type of the additional parameter to this visitor's methods. UseVoid
for visitors that do not need an additional parameter.
- All Known Implementing Classes:
DocTreePathScanner
,DocTreeScanner
,SimpleDocTreeVisitor
public interface DocTreeVisitor<R,P>
A visitor of trees, in the style of the visitor design pattern.
Classes implementing this interface are used to operate
on a tree when the kind of tree is unknown at compile time.
When a visitor is passed to an tree's
accept
method, the visitXyz
method most applicable
to that tree is invoked.
Classes implementing this interface may or may not throw a
NullPointerException
if the additional parameter p
is null
; see documentation of the implementing class for
details.
WARNING: It is possible that methods will be added to this interface to accommodate new, currently unknown, doc comment structures added to future versions of the Java™ programming language. Therefore, visitor classes directly implementing this interface may be source incompatible with future versions of the platform.
- Since:
- 1.8
-
Method Summary
Modifier and Type Method Description R
visitAttribute(AttributeTree node, P p)
Visits an AttributeTree node.R
visitAuthor(AuthorTree node, P p)
Visits an AuthorTree node.R
visitComment(CommentTree node, P p)
Visits a CommentTree node.R
visitDeprecated(DeprecatedTree node, P p)
Visits a DeprecatedTree node.R
visitDocComment(DocCommentTree node, P p)
Visits a DocCommentTree node.R
visitDocRoot(DocRootTree node, P p)
Visits a DocRootTree node.default R
visitDocType(DocTypeTree node, P p)
Visits a DocTypeTree node.R
visitEndElement(EndElementTree node, P p)
Visits an EndElementTree node.R
visitEntity(EntityTree node, P p)
Visits an EntityTree node.R
visitErroneous(ErroneousTree node, P p)
Visits an ErroneousTree node.default R
visitHidden(HiddenTree node, P p)
Visits a HiddenTree node.R
visitIdentifier(IdentifierTree node, P p)
Visits an IdentifierTree node.default R
visitIndex(IndexTree node, P p)
Visits an IndexTree node.R
visitInheritDoc(InheritDocTree node, P p)
Visits an InheritDocTree node.R
visitLink(LinkTree node, P p)
Visits a LinkTree node.R
visitLiteral(LiteralTree node, P p)
Visits an LiteralTree node.R
visitOther(DocTree node, P p)
Visits an unknown type of DocTree node.R
visitParam(ParamTree node, P p)
Visits a ParamTree node.default R
visitProvides(ProvidesTree node, P p)
Visits a ProvidesTree node.R
visitReference(ReferenceTree node, P p)
Visits a ReferenceTree node.R
visitReturn(ReturnTree node, P p)
Visits a ReturnTree node.R
visitSee(SeeTree node, P p)
Visits a SeeTree node.R
visitSerial(SerialTree node, P p)
Visits a SerialTree node.R
visitSerialData(SerialDataTree node, P p)
Visits a SerialDataTree node.R
visitSerialField(SerialFieldTree node, P p)
Visits a SerialFieldTree node.R
visitSince(SinceTree node, P p)
Visits a SinceTree node.R
visitStartElement(StartElementTree node, P p)
Visits a StartElementTree node.default R
visitSummary(SummaryTree node, P p)
Visits a SummaryTree node.default R
visitSystemProperty(SystemPropertyTree node, P p)
Visits a SystemPropertyTree node.R
visitText(TextTree node, P p)
Visits a TextTree node.R
visitThrows(ThrowsTree node, P p)
Visits a ThrowsTree node.R
visitUnknownBlockTag(UnknownBlockTagTree node, P p)
Visits an UnknownBlockTagTree node.R
visitUnknownInlineTag(UnknownInlineTagTree node, P p)
Visits an UnknownInlineTagTree node.default R
visitUses(UsesTree node, P p)
Visits a UsesTree node.R
visitValue(ValueTree node, P p)
Visits a ValueTree node.R
visitVersion(VersionTree node, P p)
Visits a VersionTreeTree node.
-
Method Details
-
visitAttribute
Visits an AttributeTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitAuthor
Visits an AuthorTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitComment
Visits a CommentTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitDeprecated
Visits a DeprecatedTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitDocComment
Visits a DocCommentTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitDocRoot
Visits a DocRootTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitDocType
Visits a DocTypeTree node.- Implementation Requirements:
- Visits a
DocTypeTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 10
-
visitEndElement
Visits an EndElementTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitEntity
Visits an EntityTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitErroneous
Visits an ErroneousTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitHidden
Visits a HiddenTree node.- Implementation Requirements:
- Visits a
HiddenTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 9
-
visitIdentifier
Visits an IdentifierTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitIndex
Visits an IndexTree node.- Implementation Requirements:
- Visits an
IndexTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 9
-
visitInheritDoc
Visits an InheritDocTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitLink
Visits a LinkTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitLiteral
Visits an LiteralTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitParam
Visits a ParamTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitProvides
Visits a ProvidesTree node.- Implementation Requirements:
- Visits a
ProvidesTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 9
-
visitReference
Visits a ReferenceTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitReturn
Visits a ReturnTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitSee
Visits a SeeTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitSerial
Visits a SerialTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitSerialData
Visits a SerialDataTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitSerialField
Visits a SerialFieldTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitSince
Visits a SinceTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitStartElement
Visits a StartElementTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitSummary
Visits a SummaryTree node.- Implementation Requirements:
- Visits a
SummaryTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 10
-
visitSystemProperty
Visits a SystemPropertyTree node.- Implementation Requirements:
- Visits a
SystemPropertyTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 12
-
visitText
Visits a TextTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitThrows
Visits a ThrowsTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitUnknownBlockTag
Visits an UnknownBlockTagTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitUnknownInlineTag
Visits an UnknownInlineTagTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitUses
Visits a UsesTree node.- Implementation Requirements:
- Visits a
UsesTree
node by callingvisitOther(node, p)
. - Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
- Since:
- 9
-
visitValue
Visits a ValueTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitVersion
Visits a VersionTreeTree node.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-
visitOther
Visits an unknown type of DocTree node. This can occur if the set of tags evolves and new kinds of nodes are added to theDocTree
hierarchy.- Parameters:
node
- the node being visitedp
- a parameter value- Returns:
- a result value
-