public abstract class TextContainer extends TextElement implements TextNode
| Modifier and Type | Field and Description |
|---|---|
protected List<TextContainer> |
children |
protected TextContainer |
nextSibling |
protected TextContainer |
parent |
protected TextContainer |
prevSibling |
| Modifier | Constructor and Description |
|---|---|
protected |
TextContainer()
Default constructor for empty text container.
|
protected |
TextContainer(TextElementType type,
List<? extends TextContainer> children)
Construct a container of element type with the specified children.
|
protected |
TextContainer(TextElementType type,
String value)
Construct a container of element type with a specific value.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object obj) |
int |
getChildCount()
Get the number of direct children of this node.
|
List<TextContainer> |
getChildren()
Get the ordered list of direct children of this node.
|
static TokenDecoder |
getDecoder() |
static TokenEncoder |
getEncoder() |
ListIterator<TextContainer> |
getIterator()
Get an iterator over all descendants of this node including this node.
|
ListIterator<TextContainer> |
getIterator(TextElementType type)
Get an iterator over the node and all descendants of this node of the specified type.
|
TextNode |
getNextSibling()
Get the right sibling of this node or null if this node has no right sibling.
|
TextNode |
getParent()
Get the parent node of this node or null if this node is the root.
|
ListIterator<TextContainer> |
getPostIterator() |
ListIterator<TextContainer> |
getPostIterator(TextElementType type) |
TextNode |
getPrevSibling()
Get the left sibling of this node or null if this node has no left sibling.
|
int |
hashCode() |
String |
toString() |
getType, getValueprotected final List<TextContainer> children
protected TextContainer parent
protected TextContainer prevSibling
protected TextContainer nextSibling
protected TextContainer()
protected TextContainer(TextElementType type, List<? extends TextContainer> children)
type - the type of this text elementchildren - the children of this containerprotected TextContainer(TextElementType type, String value)
type - the type of this text elementvalue - the text value of this containerpublic int getChildCount()
TextNodegetChildCount in interface TextNodepublic TextNode getParent()
TextNodepublic TextNode getPrevSibling()
TextNodegetPrevSibling in interface TextNodepublic TextNode getNextSibling()
TextNodegetNextSibling in interface TextNodepublic List<TextContainer> getChildren()
TextNodegetChildren in interface TextNodepublic ListIterator<TextContainer> getIterator()
TextNodegetIterator in interface TextNodepublic ListIterator<TextContainer> getIterator(TextElementType type)
TextNodegetIterator in interface TextNodetype - the type of nodes to iterate overpublic ListIterator<TextContainer> getPostIterator()
public ListIterator<TextContainer> getPostIterator(TextElementType type)
public int hashCode()
hashCode in class TextElementpublic boolean equals(Object obj)
equals in class TextElementpublic static TokenEncoder getEncoder()
public static TokenDecoder getDecoder()
Copyright © 2016 Actian Corporation. All rights reserved.