public class SimpleBeanModelNode extends BeanModelNode
SettingsPersistenceUtil.PersistentSequence
and BeanModelNodeSeq
.
This intermediary representation decouples the XML representation from the business logic, allowing several parsers / serializers to coexist for different versions of the schema.
Constructor | Description |
---|---|
SimpleBeanModelNode(java.lang.Class<?> nodeType) |
Modifier and Type | Method | Description |
---|---|---|
protected <U> void |
accept(BeanNodeVisitor<U> visitor,
U data) |
Accepts a visitor.
|
void |
addChild(BeanModelNodeSeq<?> seq) |
Add a sequence of nodes as a child of this node.
|
void |
addChild(SimpleBeanModelNode child) |
Add a node to the children of this node.
|
void |
addProperty(java.lang.String propertyKey,
java.lang.Object value,
java.lang.Class<?> type) |
Add one more property with its value.
|
boolean |
equals(java.lang.Object o) |
|
java.util.Map<java.lang.Class<?>,BeanModelNode> |
getChildrenByType() |
Returns a map of children by type.
|
java.util.List<? extends BeanModelNode> |
getChildrenNodes() |
|
java.lang.Class<?> |
getNodeType() |
Get the type of the settings owner represented by this node.
|
java.util.Set<BeanModelNodeSeq<?>> |
getSequenceProperties() |
Gets the sequences of nodes registered as children.
|
java.util.Map<java.lang.String,java.lang.Class<?>> |
getSettingsTypes() |
Returns a map of property names to their type.
|
java.util.Map<java.lang.String,java.lang.Object> |
getSettingsValues() |
Returns a map of property names to their value.
|
int |
hashCode() |
childrenAccept
public void addProperty(java.lang.String propertyKey, java.lang.Object value, java.lang.Class<?> type)
propertyKey
- Unique name identifying the property.value
- Valuetype
- Type of the propertypublic void addChild(BeanModelNodeSeq<?> seq)
seq
- Sequence of nodespublic void addChild(SimpleBeanModelNode child)
child
- Nodepublic java.util.Map<java.lang.String,java.lang.Object> getSettingsValues()
public java.util.Map<java.lang.String,java.lang.Class<?>> getSettingsTypes()
public java.util.Map<java.lang.Class<?>,BeanModelNode> getChildrenByType()
public java.util.List<? extends BeanModelNode> getChildrenNodes()
getChildrenNodes
in class BeanModelNode
public java.util.Set<BeanModelNodeSeq<?>> getSequenceProperties()
public java.lang.Class<?> getNodeType()
protected <U> void accept(BeanNodeVisitor<U> visitor, U data)
BeanModelNode
accept
in class BeanModelNode
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
Copyright © 2002–2018 PMD. All rights reserved.