public class XMLChoiceCollectionMappingUnmarshalNodeValue extends NodeValue implements ContainerValue
Purpose: This is how the XML Choice Collection Mapping is handled when used with the TreeObjectBuilder.
Constructor and Description |
---|
XMLChoiceCollectionMappingUnmarshalNodeValue(XMLChoiceCollectionMapping mapping,
XMLField xmlField) |
XMLChoiceCollectionMappingUnmarshalNodeValue(XMLChoiceCollectionMapping mapping,
XMLField xmlField,
XMLMapping nestedMapping) |
Modifier and Type | Method and Description |
---|---|
void |
attribute(UnmarshalRecord unmarshalRecord,
java.lang.String URI,
java.lang.String localName,
java.lang.String value)
The underlying choice element node value will handle attributes.
|
void |
endElement(XPathFragment xPathFragment,
UnmarshalRecord unmarshalRecord)
INTERNAL:
|
java.util.Collection<NodeValue> |
getAllNodeValues() |
NodeValue |
getChoiceElementMarshalNodeValue() |
NodeValue |
getChoiceElementNodeValue() |
java.lang.Object |
getContainerInstance() |
ContainerPolicy |
getContainerPolicy() |
int |
getIndex()
INTERNAL:
Set to track the index of the corresponding containerInstance in the containerInstances Object[] on UnmarshalRecord
Set during TreeObjectBuilder initialization
|
XMLChoiceCollectionMapping |
getMapping() |
boolean |
getReuseContainer()
Return true if the original container on the object should be used if
present.
|
boolean |
isContainerValue()
INTERNAL:
|
boolean |
isDefaultEmptyContainer()
INTERNAL
Return true if an empty container should be set on the object if there
is no presence of the collection in the XML document.
|
boolean |
isMarshalNodeValue() |
boolean |
isMixedContentNodeValue()
INTERNAL:
Return true if this is the node value representing mixed content.
|
boolean |
isOwningNode(XPathFragment xPathFragment)
INTERNAL:
|
boolean |
isUnmarshalNodeValue() |
boolean |
isWrapperAllowedAsCollectionName()
For media types that provide a native representation of collections (such
as JSON arrays), can the representation be simplified so that the
grouping element can be used as the collection name.
|
boolean |
marshal(XPathFragment xPathFragment,
MarshalRecord marshalRecord,
java.lang.Object object,
AbstractSession session,
NamespaceResolver namespaceResolver)
INTERNAL:
|
boolean |
marshalSingleValue(XPathFragment xPathFragment,
MarshalRecord marshalRecord,
java.lang.Object object,
java.lang.Object value,
AbstractSession session,
NamespaceResolver namespaceResolver,
MarshalContext marshalContext)
INTERNAL:
This method provides an optimization in cases where the value has already
been calculated.
|
void |
setContainerInstance(java.lang.Object object,
java.lang.Object containerInstance) |
void |
setContainerNodeValue(XMLChoiceCollectionMappingUnmarshalNodeValue nodeValue) |
void |
setFieldToNodeValues(java.util.Map<XMLField,NodeValue> fieldToNodeValues) |
void |
setIndex(int index)
INTERNAL:
Used to track the index of the corresponding containerInstance in the containerInstances Object[] on UnmarshalRecord
|
void |
setIsMixedNodeValue(boolean isMixed)
INTERNAL:
Indicates that this is the choice mapping node value that represents the mixed content.
|
void |
setNullValue(java.lang.Object object,
Session session) |
void |
setXPathNode(XPathNode xPathNode) |
boolean |
startElement(XPathFragment xPathFragment,
UnmarshalRecord unmarshalRecord,
org.xml.sax.Attributes atts)
INTERNAL:
|
buildSelfRecord, endElement, endSelfNodeValue, getXPathNode, isAnyMappingNodeValue, isMappingNodeValue, isMarshalOnlyNodeValue, isNullCapableValue, isWhitespaceAware, isWrapperNodeValue, marshal, marshal, marshal, marshalSelfAttributes, marshalSingleValue
public XMLChoiceCollectionMappingUnmarshalNodeValue(XMLChoiceCollectionMapping mapping, XMLField xmlField)
public XMLChoiceCollectionMappingUnmarshalNodeValue(XMLChoiceCollectionMapping mapping, XMLField xmlField, XMLMapping nestedMapping)
public boolean isOwningNode(XPathFragment xPathFragment)
NodeValue
isOwningNode
in class NodeValue
public void setContainerNodeValue(XMLChoiceCollectionMappingUnmarshalNodeValue nodeValue)
public void setNullValue(java.lang.Object object, Session session)
public void endElement(XPathFragment xPathFragment, UnmarshalRecord unmarshalRecord)
NodeValue
endElement
in class NodeValue
public boolean startElement(XPathFragment xPathFragment, UnmarshalRecord unmarshalRecord, org.xml.sax.Attributes atts)
NodeValue
startElement
in class NodeValue
public void setXPathNode(XPathNode xPathNode)
setXPathNode
in class NodeValue
public java.lang.Object getContainerInstance()
getContainerInstance
in interface ContainerValue
public void setContainerInstance(java.lang.Object object, java.lang.Object containerInstance)
setContainerInstance
in interface ContainerValue
public ContainerPolicy getContainerPolicy()
getContainerPolicy
in interface ContainerValue
public boolean isContainerValue()
NodeValue
isContainerValue
in class NodeValue
ContainerValue
public boolean marshalSingleValue(XPathFragment xPathFragment, MarshalRecord marshalRecord, java.lang.Object object, java.lang.Object value, AbstractSession session, NamespaceResolver namespaceResolver, MarshalContext marshalContext)
NodeValue
marshalSingleValue
in interface ContainerValue
marshalSingleValue
in class NodeValue
public boolean marshal(XPathFragment xPathFragment, MarshalRecord marshalRecord, java.lang.Object object, AbstractSession session, NamespaceResolver namespaceResolver)
NodeValue
public NodeValue getChoiceElementNodeValue()
public NodeValue getChoiceElementMarshalNodeValue()
public boolean isUnmarshalNodeValue()
isUnmarshalNodeValue
in class NodeValue
public boolean isWrapperAllowedAsCollectionName()
ContainerValue
isWrapperAllowedAsCollectionName
in interface ContainerValue
public boolean isMarshalNodeValue()
isMarshalNodeValue
in class NodeValue
public XMLChoiceCollectionMapping getMapping()
getMapping
in interface ContainerValue
public boolean getReuseContainer()
ContainerValue
getReuseContainer
in interface ContainerValue
public void setFieldToNodeValues(java.util.Map<XMLField,NodeValue> fieldToNodeValues)
public java.util.Collection<NodeValue> getAllNodeValues()
public void attribute(UnmarshalRecord unmarshalRecord, java.lang.String URI, java.lang.String localName, java.lang.String value)
public void setIsMixedNodeValue(boolean isMixed)
public boolean isMixedContentNodeValue()
isMixedContentNodeValue
in class NodeValue
public void setIndex(int index)
setIndex
in interface ContainerValue
public int getIndex()
getIndex
in interface ContainerValue
public boolean isDefaultEmptyContainer()
isDefaultEmptyContainer
in interface ContainerValue
EclipseLink 2.4.2, "build v20130514-5956486" API Reference