public class Embeddable extends Object implements ConfigurationNode, XMLSerializable, Serializable
Modifier and Type | Field and Description |
---|---|
protected Map<String,EmbeddableAttribute> |
attributes |
protected String |
className |
protected DataMap |
dataMap |
Constructor and Description |
---|
Embeddable() |
Embeddable(String className) |
Modifier and Type | Method and Description |
---|---|
<T> T |
acceptVisitor(ConfigurationNodeVisitor<T> visitor) |
void |
addAttribute(EmbeddableAttribute attribute)
Adds new embeddable attribute to the entity, setting its parent
embeddable to be this object.
|
void |
encodeAsXML(XMLEncoder encoder,
ConfigurationNodeVisitor delegate)
XMLSerializable implementation that generates XML for embeddable. |
EmbeddableAttribute |
getAttribute(String name) |
EmbeddableAttribute |
getAttributeForDbPath(String dbPath)
Returns EmbeddableAttribute of this Embeddable that maps to
dbAttribute parameter. |
Map<String,EmbeddableAttribute> |
getAttributeMap()
Returns an unmodifiable sorted map of embeddable attributes.
|
Collection<EmbeddableAttribute> |
getAttributes()
Returns an unmodifiable collection of embeddable attributes.
|
String |
getClassName() |
DataMap |
getDataMap() |
void |
removeAttribute(String name) |
void |
setClassName(String className) |
void |
setDataMap(DataMap dataMap) |
protected String className
protected Map<String,EmbeddableAttribute> attributes
protected DataMap dataMap
public Embeddable()
public Embeddable(String className)
public <T> T acceptVisitor(ConfigurationNodeVisitor<T> visitor)
acceptVisitor
in interface ConfigurationNode
public DataMap getDataMap()
public void setDataMap(DataMap dataMap)
public EmbeddableAttribute getAttributeForDbPath(String dbPath)
dbAttribute
parameter. Returns null if no such attribute is
found.public Map<String,EmbeddableAttribute> getAttributeMap()
public Collection<EmbeddableAttribute> getAttributes()
public void addAttribute(EmbeddableAttribute attribute)
public EmbeddableAttribute getAttribute(String name)
public void removeAttribute(String name)
public String getClassName()
public void setClassName(String className)
public void encodeAsXML(XMLEncoder encoder, ConfigurationNodeVisitor delegate)
XMLSerializable
implementation that generates XML for embeddable.encodeAsXML
in interface XMLSerializable
Copyright © 2001–2019 Apache Cayenne. All rights reserved.