Class WikiTextNode
java.lang.Object
com.lucaskjaerozhang.wikitext_parser.ast.base.WikiTextNode
- All Implemented Interfaces:
WikiTextElement
- Direct Known Subclasses:
HorizontalRule,LineBreak,Redirect,Text,UnnamedExternalLink,WikiTextParentNode,XMLStandaloneElement
The interface for all types of AST nodes.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract <T> Optional<T>accept(WikiTextASTVisitor<T> visitor) Hook for an AST visitor.Base case for getting element attributes.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.lucaskjaerozhang.wikitext_parser.ast.base.WikiTextElement
getCategories
-
Constructor Details
-
WikiTextNode
public WikiTextNode()
-
-
Method Details
-
accept
Hook for an AST visitor.- Type Parameters:
T- Whatever the visitor produces.- Parameters:
visitor- The visitor doing the visitor.- Returns:
- Whatever the visitor produced.
-
getAttributes
Base case for getting element attributes. Most nodes have no attributes- Returns:
- Attributes
-
rebuildWithContext
-