org.beanio.internal.parser
Class ParserComponent
java.lang.Object
org.beanio.internal.util.TreeNode<Component>
org.beanio.internal.parser.Component
org.beanio.internal.parser.ParserComponent
- All Implemented Interfaces:
- Cloneable, Iterable<Component>, Parser, Replicateable
- Direct Known Subclasses:
- DelegatingParser, Field, Group, Segment, XmlSelectorWrapper
public abstract class ParserComponent
- extends Component
- implements Parser
Base class for all parser components in that implement Parser
.
The method isSupportedChild(Component)
is overridden to restrict
children to components that also implement Parser
.
- Since:
- 2.0
- Author:
- Kevin Seim
- See Also:
Parser
Methods inherited from class org.beanio.internal.util.TreeNode |
add, clone, find, getChildren, getFirst, getName, iterator, print, setName, size, sort, toParamString, toString, updateReferences |
Methods inherited from interface org.beanio.internal.parser.Parser |
clearValue, getName, getSize, getValue, hasContent, isIdentifier, isLazy, marshal, matches, setValue, unmarshal |
ParserComponent
public ParserComponent()
- Constructs a new ParserComponent.
ParserComponent
public ParserComponent(int size)
- Constructs a new ParserComponent.
- Parameters:
size
- the initial child capacity
isSupportedChild
protected boolean isSupportedChild(Component child)
- Description copied from class:
TreeNode
- Returns whether a node is a supported child of this node. Called
by
TreeNode.add(TreeNode)
.
- Overrides:
isSupportedChild
in class TreeNode<Component>
- Parameters:
child
- the node to test
- Returns:
- true if the child is allowed
Copyright © 2010-2013 Kevin Seim