|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.axiom.om.impl.dom.NodeImpl
org.apache.axiom.om.impl.dom.ChildNode
org.apache.axiom.om.impl.dom.CharacterImpl
org.apache.axiom.om.impl.dom.TextImpl
public class TextImpl
| Field Summary | |
|---|---|
protected OMAttribute |
attribute
Field attribute is used when serializing Binary stuff as MTOM optimized. |
protected char[] |
charArray
|
protected String |
localName
Field localName is used when serializing Binary stuff as MTOM optimized. |
protected OMNamespace |
ns
Field nameSpace is used when serializing Binary stuff as MTOM optimized. |
protected OMNamespace |
textNS
|
static OMNamespace |
XOP_NS
Field nameSpace used when serializing Binary stuff as MTOM optimized. |
| Fields inherited from class org.apache.axiom.om.impl.dom.CharacterImpl |
|---|
textValue |
| Fields inherited from class org.apache.axiom.om.impl.dom.ChildNode |
|---|
nextSibling, parentNode, previousSibling |
| Fields inherited from class org.apache.axiom.om.impl.dom.NodeImpl |
|---|
builder, done, factory, FIRSTCHILD, flags, NORMALIZED, OWNED, ownerNode, READONLY, SPECIFIED |
| Fields inherited from interface org.w3c.dom.Node |
|---|
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE |
| Fields inherited from interface org.apache.axiom.om.OMNode |
|---|
CDATA_SECTION_NODE, COMMENT_NODE, DTD_NODE, ELEMENT_NODE, ENTITY_REFERENCE_NODE, PI_NODE, SPACE_NODE, TEXT_NODE |
| Constructor Summary | |
|---|---|
TextImpl(DocumentImpl ownerNode,
char[] value,
OMFactory factory)
|
|
TextImpl(DocumentImpl ownerNode,
Object dataHandler,
boolean optimize,
OMFactory factory)
|
|
TextImpl(DocumentImpl ownerNode,
OMFactory factory)
|
|
TextImpl(DocumentImpl ownerNode,
String value,
OMFactory factory)
|
|
TextImpl(DocumentImpl ownerNode,
String value,
String mimeType,
boolean optimize,
OMFactory factory)
|
|
TextImpl(OMContainer parent,
javax.xml.namespace.QName text,
int nodeType,
OMFactory factory)
|
|
TextImpl(OMContainer parent,
javax.xml.namespace.QName text,
OMFactory factory)
|
|
TextImpl(OMContainer parent,
TextImpl source,
OMFactory factory)
Construct TextImpl that is a copy of the source OMTextImpl |
|
TextImpl(String contentID,
OMContainer parent,
OMXMLParserWrapper builder,
OMFactory factory)
|
|
TextImpl(String text,
OMFactory factory)
Creates a text node with the given text required by the OMDOMFactory. |
|
TextImpl(String text,
String mimeType,
boolean optimize,
boolean isBinary,
OMFactory factory)
|
|
TextImpl(String text,
String mimeType,
boolean optimize,
OMFactory factory)
|
|
| Method Summary | |
|---|---|
void |
buildWithAttachments()
Parses this node and builds the object structure in memory. |
org.w3c.dom.Node |
cloneNode(boolean deep)
|
void |
discard()
Discards a node. |
String |
getContentID()
Gets the content id. |
String |
getData()
Returns the value of the data. |
Object |
getDataHandler()
Gets the datahandler. |
InputStream |
getInputStream()
|
String |
getLocalName()
|
OMNamespace |
getNamespace()
Returns the Namespace if this contains a QName Return null otherwise |
String |
getNodeName()
|
short |
getNodeType()
|
String |
getNodeValue()
|
String |
getText()
Returns the text value of this node. |
javax.xml.namespace.QName |
getTextAsQName()
|
char[] |
getTextCharacters()
|
int |
getType()
Returns the type of node. |
String |
getWholeText()
|
void |
internalSerialize(javax.xml.stream.XMLStreamWriter writer)
Serializes the node with caching. |
void |
internalSerializeAndConsume(javax.xml.stream.XMLStreamWriter writer)
Serializes the node without caching. |
boolean |
isBinary()
|
boolean |
isCharacters()
|
boolean |
isElementContentWhitespace()
|
boolean |
isOptimized()
|
org.w3c.dom.Text |
replaceWholeText(String arg0)
|
void |
setBinary(boolean value)
Receiving binary can happen as either MTOM attachments or as Base64 Text In the case of Base64 user has to explicitly specify that the content is binary, before calling getDataHandler(), getInputStream().... |
void |
setContentID(String cid)
Set a specific content id |
void |
setOptimize(boolean value)
Sets the optimize flag. |
void |
setType(int nodeType)
|
org.w3c.dom.Text |
splitText(int offset)
Breaks this node into two nodes at the specified offset, keeping both in the tree as siblings. |
String |
toString()
|
| Methods inherited from class org.apache.axiom.om.impl.dom.CharacterImpl |
|---|
appendData, deleteData, getLength, insertData, replaceData, setData, substringData |
| Methods inherited from class org.apache.axiom.om.impl.dom.ChildNode |
|---|
detach, getNextOMSibling, getNextSibling, getParent, getParentNode, getPreviousOMSibling, getPreviousSibling, insertSiblingAfter, insertSiblingBefore, setNextOMSibling, setParent, setPreviousOMSibling |
| Methods inherited from class org.apache.axiom.om.impl.dom.NodeImpl |
|---|
appendChild, build, close, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getNamespaceURI, getOMFactory, getOwnerDocument, getPrefix, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, internalSerializeWithCache, isComplete, isDefaultNamespace, isEqualNode, isSameNode, isSupported, item, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, serialize, serialize, serialize, serialize, serialize, serializeAndConsume, serializeAndConsume, serializeAndConsume, serializeAndConsume, serializeAndConsume, setComplete, setNodeValue, setOwnerDocument, setPrefix, setTextContent, setUserData |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.w3c.dom.CharacterData |
|---|
appendData, deleteData, getLength, insertData, replaceData, setData, substringData |
| Methods inherited from interface org.w3c.dom.Node |
|---|
appendChild, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getNamespaceURI, getNextSibling, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData |
| Methods inherited from interface org.apache.axiom.om.OMNode |
|---|
build, close, detach, getNextOMSibling, getOMFactory, getParent, getPreviousOMSibling, insertSiblingAfter, insertSiblingBefore, isComplete, serialize, serialize, serialize, serialize, serialize, serializeAndConsume, serializeAndConsume, serializeAndConsume, serializeAndConsume, serializeAndConsume |
| Field Detail |
|---|
protected OMNamespace textNS
protected char[] charArray
protected OMNamespace ns
protected String localName
protected OMAttribute attribute
public static final OMNamespace XOP_NS
| Constructor Detail |
|---|
public TextImpl(String text,
OMFactory factory)
text -
public TextImpl(String contentID,
OMContainer parent,
OMXMLParserWrapper builder,
OMFactory factory)
contentID - parent - builder - Used when the builder is encountered with a XOP:Include tag Stores a
reference to the builder and the content-id. Supports deffered parsing of
MIME messages
public TextImpl(OMContainer parent,
TextImpl source,
OMFactory factory)
parent - source - TextImplfactory -
public TextImpl(String text,
String mimeType,
boolean optimize,
OMFactory factory)
public TextImpl(String text,
String mimeType,
boolean optimize,
boolean isBinary,
OMFactory factory)
public TextImpl(DocumentImpl ownerNode,
Object dataHandler,
boolean optimize,
OMFactory factory)
dataHandler - optimize - To send binary content. Created progrmatically.
public TextImpl(DocumentImpl ownerNode,
OMFactory factory)
ownerNode -
public TextImpl(DocumentImpl ownerNode,
String value,
OMFactory factory)
ownerNode - value -
public TextImpl(DocumentImpl ownerNode,
char[] value,
OMFactory factory)
public TextImpl(DocumentImpl ownerNode,
String value,
String mimeType,
boolean optimize,
OMFactory factory)
ownerNode - value -
public TextImpl(OMContainer parent,
javax.xml.namespace.QName text,
OMFactory factory)
public TextImpl(OMContainer parent,
javax.xml.namespace.QName text,
int nodeType,
OMFactory factory)
| Method Detail |
|---|
public org.w3c.dom.Text splitText(int offset)
throws org.w3c.dom.DOMException
splitText in interface org.w3c.dom.Textorg.w3c.dom.DOMExceptionpublic String getNodeName()
getNodeName in interface org.w3c.dom.Nodepublic short getNodeType()
getNodeType in interface org.w3c.dom.Node
public int getType()
throws OMException
OMNode
getType in interface OMNodeOMNode.ELEMENT_NODE, OMNode.TEXT_NODE, OMNode.CDATA_SECTION_NODE,
OMNode.COMMENT_NODE, OMNode.DTD_NODE, OMNode.PI_NODE, OMNode.ENTITY_REFERENCE_NODE, OMNode.SPACE_NODE, or OMNode.TEXT_NODE.
OMException
public void setType(int nodeType)
throws OMException
setType in interface OMNodeExOMException
public void internalSerialize(javax.xml.stream.XMLStreamWriter writer)
throws javax.xml.stream.XMLStreamException
OMNodeEx
internalSerialize in interface OMNodeExjavax.xml.stream.XMLStreamException
public void internalSerializeAndConsume(javax.xml.stream.XMLStreamWriter writer)
throws javax.xml.stream.XMLStreamException
OMNodeEx
internalSerializeAndConsume in interface OMNodeExjavax.xml.stream.XMLStreamExceptionpublic boolean isOptimized()
isOptimized in interface OMTextpublic void setOptimize(boolean value)
OMText
setOptimize in interface OMTextvalue - true to optimize binary content (usually w/MTOM)
public void discard()
throws OMException
OMNode
discard in interface OMNodediscard in class ChildNodeOMExceptionpublic String getText()
OMText
getText in interface OMText
public String getData()
throws org.w3c.dom.DOMException
CharacterImpl
getData in interface org.w3c.dom.CharacterDatagetData in class CharacterImplorg.w3c.dom.DOMExceptionpublic char[] getTextCharacters()
getTextCharacters in interface OMTextpublic boolean isCharacters()
isCharacters in interface OMTextpublic javax.xml.namespace.QName getTextAsQName()
getTextAsQName in interface OMText
public String getNodeValue()
throws org.w3c.dom.DOMException
getNodeValue in interface org.w3c.dom.NodegetNodeValue in class NodeImplorg.w3c.dom.DOMExceptionpublic String getContentID()
OMText
getContentID in interface OMTextpublic Object getDataHandler()
OMText
getDataHandler in interface OMText
public InputStream getInputStream()
throws OMException
OMExceptionpublic org.w3c.dom.Node cloneNode(boolean deep)
cloneNode in interface org.w3c.dom.NodecloneNode in class ChildNodepublic String getLocalName()
getLocalName in interface org.w3c.dom.NodegetLocalName in class NodeImplpublic String getWholeText()
getWholeText in interface org.w3c.dom.Textpublic boolean isElementContentWhitespace()
isElementContentWhitespace in interface org.w3c.dom.Text
public org.w3c.dom.Text replaceWholeText(String arg0)
throws org.w3c.dom.DOMException
replaceWholeText in interface org.w3c.dom.Textorg.w3c.dom.DOMExceptionpublic String toString()
toString in class Objectpublic void buildWithAttachments()
NodeImpl
buildWithAttachments in interface OMNodebuildWithAttachments in class NodeImplpublic boolean isBinary()
isBinary in interface OMTextpublic void setBinary(boolean value)
setBinary in interface OMTextvalue - true if the content is binarypublic OMNamespace getNamespace()
OMText
getNamespace in interface OMTextpublic void setContentID(String cid)
OMText
setContentID in interface OMText
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||