Class FilterXmlObject
- java.lang.Object
-
- org.apache.xmlbeans.FilterXmlObject
-
- All Implemented Interfaces:
DelegateXmlObject,SimpleValue,XmlObject,XmlTokenSource
public abstract class FilterXmlObject extends java.lang.Object implements XmlObject, SimpleValue, DelegateXmlObject
A FilterXmlObject delegates to some other XmlObject, which it can use as its basic source of data, possibly transforming the data along the way or providing additional functionality. The class FilterXmlObject itself simply overrides all methods of XmlObject with versions that pass all requests to the underlying XmlObject. Subclasses of FilterXmlObject may further override some of these methods and may also provide additional methods and fields.Note: it is important that FilterXmlObject has no storage (i.e., no non-transient fields), because subclasses may be serializable and adding storage would break the serialization format.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.xmlbeans.XmlObject
XmlObject.Factory
-
-
Constructor Summary
Constructors Constructor Description FilterXmlObject()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description java.math.BigDecimalbigDecimalValue()Deprecated.replaced withgetBigDecimalValue()java.math.BigIntegerbigIntegerValue()Deprecated.replaced withgetBigIntegerValue()booleanbooleanValue()Deprecated.replaced withgetBooleanValue()byte[]byteArrayValue()Deprecated.replaced withgetByteArrayValue()bytebyteValue()Deprecated.replaced withgetByteValue()java.util.CalendarcalendarValue()Deprecated.replaced withgetCalendarValue()XmlObjectchangeType(SchemaType newType)Changes the schema type associated with this data and returns a new XmlObject instance whose schemaType is the new type.intcompareTo(java.lang.Object obj)Impelements the Comparable interface by comparing two simple xml values based on their standard XML schema ordering.intcompareValue(XmlObject obj)This comparison method is similar to compareTo, but rather than throwing a ClassCastException when two values are incomparable, it returns the number 2.XmlObjectcopy()Returns a deep copy of this XmlObject.XmlObjectcopy(XmlOptions options)Returns a deep copy of this XmlObject.java.util.DatedateValue()Deprecated.replaced withgetDateValue()XmlDocumentPropertiesdocumentProperties()Returns the XmlDocumentProperties object for the document this token source is associated with.doubledoubleValue()Deprecated.replaced withgetDoubleValue()StringEnumAbstractBaseenumValue()Deprecated.replaced withgetEnumValue()XmlObject[]execQuery(java.lang.String query)Executes a query.XmlObject[]execQuery(java.lang.String query, XmlOptions options)Executes a query with options.floatfloatValue()Deprecated.replaced withgetFloatValue()GDategDateValue()Deprecated.replaced withgetGDateValue()GDurationgDurationValue()Deprecated.replaced withgetGDurationValue()java.math.BigDecimalgetBigDecimalValue()Returns the value as aBigDecimal.java.math.BigIntegergetBigIntegerValue()Returns the value as aBigInteger.booleangetBooleanValue()Returns the value as a boolean.byte[]getByteArrayValue()Returns the value as a byte array.bytegetByteValue()Returns the value as a byte.java.util.CalendargetCalendarValue()Returns the value as aCalendar.java.util.DategetDateValue()Returns the value as aDate.org.w3c.dom.NodegetDomNode()Returns a W3C DOM Node containing the XML represented by this source.doublegetDoubleValue()Returns the value as a double.StringEnumAbstractBasegetEnumValue()Returns the value as aStringEnumAbstractBase.floatgetFloatValue()Returns the value as a float.GDategetGDateValue()Returns the value as aGDate.GDurationgetGDurationValue()Returns the value as aGDuration.intgetIntValue()Returns the value as an int.java.util.ListgetListValue()Returns the value as aListof friendly Java objects (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration).longgetLongValue()Returns the value as a long.java.lang.ObjectgetObjectValue()Returns a union value as a its natural friendly Java object (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration).javax.xml.namespace.QNamegetQNameValue()Returns the value as aQName.shortgetShortValue()Returns the value as a short.java.lang.StringgetStringValue()Returns the value as aString.SchemaTypeinstanceType()The same as getSchemaType unless this is a union instance or nil value.intintValue()Deprecated.replaced withgetIntValue()booleanisImmutable()Immutable values do not have a position in a tree; rather, they are stand-alone simple type values.booleanisNil()Note that in order to be nil, the value must be in an element, and the element containing the value must be marked as nillable in the schema.java.util.ListlistValue()Deprecated.replaced withgetListValue()longlongValue()Deprecated.replaced withgetLongValue()java.lang.Objectmonitor()Returns the synchronization object for the document.XmlCursornewCursor()Returns a new XML cursor.org.w3c.dom.NodenewDomNode()Returns a W3C DOM Node containing the XML represented by this source.org.w3c.dom.NodenewDomNode(XmlOptions options)Just like newDomNode() but with options.java.io.InputStreamnewInputStream()Returns a new stream containing standard XML text, encoded according to the given encoding.java.io.InputStreamnewInputStream(XmlOptions options)Just like newInputStream(String encoding) but with options.java.io.ReadernewReader()Returns a new character reader containing XML text.java.io.ReadernewReader(XmlOptions options)Just like newReader() but with options.XMLInputStreamnewXMLInputStream()Deprecated.Deprecated by XMLStreamReader from STaX - jsr173 API.XMLInputStreamnewXMLInputStream(XmlOptions options)Deprecated.Deprecated by XMLStreamReader from STaX - jsr173 API.javax.xml.stream.XMLStreamReadernewXMLStreamReader()Returns a new XMLStreamReader.javax.xml.stream.XMLStreamReadernewXMLStreamReader(XmlOptions options)Just like newXMLInputStream() but with options.voidobjectSet(java.lang.Object obj)Deprecated.replaced withsetObjectValue(java.lang.Object)java.lang.ObjectobjectValue()Deprecated.replaced withgetObjectValue()javax.xml.namespace.QNameqNameValue()Deprecated.replaced withgetQNameValue()voidsave(java.io.File file)Writes the XML represented by this source to the given File.voidsave(java.io.File file, XmlOptions options)Writes the XML represented by this source to the given File.voidsave(java.io.OutputStream os)Writes the XML represented by this source to the given output stream.voidsave(java.io.OutputStream os, XmlOptions options)Writes the XML represented by this source to the given output stream.voidsave(java.io.Writer w)Writes the XML represented by this source to the given output.voidsave(java.io.Writer w, XmlOptions options)Writes the XML represented by this source to the given output.voidsave(org.xml.sax.ContentHandler ch, org.xml.sax.ext.LexicalHandler lh)Writes the XML represented by this source to the given SAX content and lexical handlers.voidsave(org.xml.sax.ContentHandler ch, org.xml.sax.ext.LexicalHandler lh, XmlOptions options)Writes the XML represented by this source to the given SAX content and lexical handlers.SchemaTypeschemaType()XmlObjectselectAttribute(java.lang.String attributeUri, java.lang.String attributeLocalName)Selects the content of the attribute with the given name.XmlObjectselectAttribute(javax.xml.namespace.QName attributeName)Selects the content of the attribute with the given name.XmlObject[]selectAttributes(QNameSet attributeNameSet)Selects the contents of the attributes that are contained in the elementNameSet.XmlObject[]selectChildren(java.lang.String elementUri, java.lang.String elementLocalName)Selects the contents of the children elements with the given name.XmlObject[]selectChildren(javax.xml.namespace.QName elementName)Selects the contents of the children elements with the given name.XmlObject[]selectChildren(QNameSet elementNameSet)Selects the contents of the children elements that are contained in the elementNameSet.XmlObject[]selectPath(java.lang.String path)Selects a path.XmlObject[]selectPath(java.lang.String path, XmlOptions options)Selects a path, applying options.voidset(boolean v)Deprecated.replaced withsetBooleanValue(boolean)voidset(byte v)Deprecated.replaced withsetByteValue(byte)voidset(byte[] obj)Deprecated.replaced withsetByteArrayValue(byte[])voidset(double v)Deprecated.replaced withsetDoubleValue(double)voidset(float v)Deprecated.replaced withsetFloatValue(float)voidset(int v)Deprecated.replaced withsetIntValue(int)voidset(long v)Deprecated.replaced withsetLongValue(long)voidset(short v)Deprecated.replaced withsetShortValue(short)voidset(java.lang.String obj)Deprecated.replaced withsetStringValue(java.lang.String)voidset(java.math.BigDecimal obj)Deprecated.replaced withsetBigDecimalValue(java.math.BigDecimal)voidset(java.math.BigInteger obj)Deprecated.replaced withsetBigIntegerValue(java.math.BigInteger)voidset(java.util.Calendar obj)Deprecated.replaced withsetCalendarValue(java.util.Calendar)voidset(java.util.Date obj)Deprecated.replaced withsetDateValue(java.util.Date)voidset(java.util.List obj)Deprecated.replaced withsetListValue(java.util.List)voidset(javax.xml.namespace.QName obj)Deprecated.replaced withsetQNameValue(javax.xml.namespace.QName)voidset(GDateSpecification obj)Deprecated.replaced withsetGDateValue(org.apache.xmlbeans.GDate)voidset(GDurationSpecification obj)Deprecated.replaced withsetGDurationValue(org.apache.xmlbeans.GDuration)voidset(StringEnumAbstractBase obj)Deprecated.replaced withsetEnumValue(org.apache.xmlbeans.StringEnumAbstractBase)XmlObjectset(XmlObject srcObj)Set the value/type of this XmlObject to be a copy of the source XmlObject.voidsetBigDecimalValue(java.math.BigDecimal obj)Sets the value as aBigDecimal.voidsetBigIntegerValue(java.math.BigInteger obj)Sets the value as aBigInteger.voidsetBooleanValue(boolean v)Sets the value as a boolean.voidsetByteArrayValue(byte[] obj)Sets the value as a byte array.voidsetByteValue(byte v)Sets the value as a byte.voidsetCalendarValue(java.util.Calendar obj)Sets the value as aCalendar.voidsetDateValue(java.util.Date obj)Sets the value as aDate.voidsetDoubleValue(double v)Sets the value as a double.voidsetEnumValue(StringEnumAbstractBase obj)Sets the value as aStringEnumAbstractBase.voidsetFloatValue(float v)Sets the value as a float.voidsetGDateValue(GDate obj)Sets the value as aGDate.voidsetGDurationValue(GDuration obj)Sets the value as aGDuration.voidsetIntValue(int v)Sets the value as an int.voidsetListValue(java.util.List obj)Sets the value as aList.voidsetLongValue(long v)Sets the value as a long.voidsetNil()Sets the value to nil.voidsetObjectValue(java.lang.Object obj)Sets the value as an arbitraryObject.voidsetQNameValue(javax.xml.namespace.QName obj)Sets the value as aQName.voidsetShortValue(short v)Sets the value as a short.voidsetStringValue(java.lang.String obj)Sets the value as aString.shortshortValue()Deprecated.replaced withgetShortValue()java.lang.StringstringValue()Deprecated.replaced withgetStringValue()booleanvalidate()Does a deep validation of the entire subtree under the object, but does not validate the parents or siblings of the object if the object is in the interior of an xml tree.booleanvalidate(XmlOptions options)Just like validate(), but with options.booleanvalueEquals(XmlObject obj)True if the xml values are equal.intvalueHashCode()java.util.ListxgetListValue()Returns the value as aListof XmlAnySimpleType objects.java.util.ListxlistValue()Deprecated.replaced withgetListValue()java.lang.StringxmlText()Returns standard XML text.java.lang.StringxmlText(XmlOptions options)Just like xmlText() but with options.-
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.xmlbeans.DelegateXmlObject
underlyingXmlObject
-
Methods inherited from interface org.apache.xmlbeans.XmlObject
substitute, toString
-
Methods inherited from interface org.apache.xmlbeans.XmlTokenSource
dump
-
-
-
-
Method Detail
-
schemaType
public SchemaType schemaType()
- Specified by:
schemaTypein interfaceXmlObject- Returns:
- The schema type for this instance. This is a permanent, unchanging property of the instance.
-
validate
public boolean validate()
Description copied from interface:XmlObjectDoes a deep validation of the entire subtree under the object, but does not validate the parents or siblings of the object if the object is in the interior of an xml tree.
-
validate
public boolean validate(XmlOptions options)
Description copied from interface:XmlObjectJust like validate(), but with options.
If you wish to collect error messages and locations while validating, use the
XmlOptions.setErrorListener(java.util.Collection)method. With that method, you can specify an object in which to store messages related to validation. The following is a simple example.// Create an XmlOptions instance and set the error listener. XmlOptions validateOptions = new XmlOptions(); ArrayList errorList = new ArrayList(); validateOptions.setErrorListener(errorList); // Validate the XML. boolean isValid = newEmp.validate(validateOptions); // If the XML isn't valid, loop through the listener's contents, // printing contained messages. if (!isValid) { for (int i = 0; i < errorList.size(); i++) { XmlError error = (XmlError)errorList.get(i); System.out.println("\n"); System.out.println("Message: " + error.getMessage() + "\n"); System.out.println("Location of invalid XML: " + error.getCursorLocation().xmlText() + "\n"); } }
-
selectPath
public XmlObject[] selectPath(java.lang.String path)
Description copied from interface:XmlObjectSelects a path. Path can be a string or precompiled path String.The path must be a relative path, where "." represents the element or attribute containg this XmlObject, and it must select only other elements or attributes. If a non-element or non-attribute is selected, an unchecked exception is thrown.
The array that is returned contains all the selected XmlObjects, within the same document, listed in document order. The actual array type of the result is inferred from the closest common base type of selected results.
Here is an example of usage. Suppose we have a global element definition for "owner" whose type is "person":
<schema targetNamespace="http://openuri.org/sample"> <element name="owner" type="person"/> <complexType name="person"> [...] </complexType> </schema>and suppose "owner" tags can be scattered throughout the document. Then we can write the following code to find them all:import org.openuri.sample.Person; import org.apache.xmlbeans.*; [...] XmlObject xobj = XmlObject.Factory.parse(myFile); Person[] results; results = (Person[])xobj.selectPath( "declare namespace s='http://www.openuri.org/sample' " + ".//s:owner");Notice the way in which namespace declarations are done in XPath 2.0. Since XPath can only navigate within an XML document - it cannot construct new XML - the resulting XmlObjects all reside in the same XML document as this XmlObject itself.- Specified by:
selectPathin interfaceXmlObject- Parameters:
path- the xpath- Returns:
- an array of all selected XmlObjects
-
selectPath
public XmlObject[] selectPath(java.lang.String path, XmlOptions options)
Description copied from interface:XmlObjectSelects a path, applying options.- Specified by:
selectPathin interfaceXmlObject- Parameters:
path- the xpathoptions- the options used to execute the xpath- Returns:
- an array of all selected XmlObjects
- See Also:
XmlObject.selectPath(String)
-
execQuery
public XmlObject[] execQuery(java.lang.String query)
Description copied from interface:XmlObjectExecutes a query. Query can be a string or precompiled query String.An XQuery is very similar to an XPath, except that it also permits construction of new XML. As a result, the XmlObjects that are returned from execQuery are in newly created documents, separate from the XmlObject on which the query is executed.
Syntax and usage is otherwise similar to selectPath.
- Specified by:
execQueryin interfaceXmlObject- Parameters:
query- The XQuery expression- Returns:
- an array of all selected XmlObjects
- See Also:
XmlObject.selectPath(String)
-
execQuery
public XmlObject[] execQuery(java.lang.String query, XmlOptions options)
Description copied from interface:XmlObjectExecutes a query with options. Use the options parameter to specify the following:To specify this Use this method The document type for the root element. XmlOptions.setDocumentType(org.apache.xmlbeans.SchemaType)To replace the document element with the specified QName when constructing the resulting document. XmlOptions.setLoadReplaceDocumentElement(javax.xml.namespace.QName)To strip all insignificant whitespace when constructing a document. XmlOptions.setLoadStripWhitespace()To strip all comments when constructing a document. XmlOptions.setLoadStripComments()To strip all processing instructions when constructing a document. XmlOptions.setLoadStripProcinsts()A map of namespace URI substitutions to use when constructing a document. XmlOptions.setLoadSubstituteNamespaces(java.util.Map)Additional namespace mappings to be added when constructing a document. XmlOptions.setLoadAdditionalNamespaces(java.util.Map)To trim the underlying XML text buffer immediately after constructing a document, resulting in a smaller memory footprint. XmlOptions.setLoadTrimTextBuffer()Whether value facets should be checked as they are set. XmlOptions.setValidateOnSet()- Specified by:
execQueryin interfaceXmlObject- Parameters:
query- The XQuery expression.options- Options as described.- Returns:
- an array of all selected XmlObjects
- See Also:
XmlObject.execQuery(String)
-
changeType
public XmlObject changeType(SchemaType newType)
Description copied from interface:XmlObjectChanges the schema type associated with this data and returns a new XmlObject instance whose schemaType is the new type.Returns the new XmlObject if the type change was successful, the old XmlObject if no changes could be made.
Certain type changes may be prohibited in the interior of an xml tree due to schema type system constraints (that is, due to a parent container within which the newly specified type is not permissible), but there are no constraints at the roottype changes are never prohibited at the root of an xml tree.If the type change is allowed, then the new XmlObject should be used rather than the old one. The old XmlObject instance and any other XmlObject instances in the subtree are permanently invalidated and should not be used. (They will return XmlValueDisconnectedException if you try to use them.) If a type change is done on the interior of an Xml tree, then xsi:type attributes are updated as needed.
- Specified by:
changeTypein interfaceXmlObject- Returns:
- a new XmlObject instance whose schemaType is the new type
-
isNil
public boolean isNil()
Description copied from interface:XmlObjectNote that in order to be nil, the value must be in an element, and the element containing the value must be marked as nillable in the schema.
-
setNil
public void setNil()
Description copied from interface:XmlObjectSets the value to nil. The element containing the value must be marked as nillable in the schema.
-
isImmutable
public boolean isImmutable()
Description copied from interface:XmlObjectImmutable values do not have a position in a tree; rather, they are stand-alone simple type values. If the object is immutable, the equals() methods tests for value equality, and the object can be used as the key for a hash.- Specified by:
isImmutablein interfaceXmlObject- Returns:
- true if the value is an immutable value.
-
set
public XmlObject set(XmlObject srcObj)
Description copied from interface:XmlObjectSet the value/type of this XmlObject to be a copy of the source XmlObject. Because the type of the source may be different than this target, this XmlObject may become defunct. In this case the new XmlObject is returned. If no type change happens, the same this will be returned.
-
copy
public XmlObject copy()
Description copied from interface:XmlObjectReturns a deep copy of this XmlObject. The returned object has the same type as the current object, and has all the content of the XML document underneath the current object. Note that any parts of the XML document above or outside this XmlObject are not copied. Note: The result object will be in the same synchronization domain as the source, and additional synchronization is required for concurent access. To use a different synchronization domain use setCopyUseNewSynchronizationDomain option with copy(XmlOptions) method.- Specified by:
copyin interfaceXmlObject- See Also:
XmlObject.copy(XmlOptions),XmlOptions.setCopyUseNewSynchronizationDomain(boolean)
-
copy
public XmlObject copy(XmlOptions options)
Description copied from interface:XmlObjectReturns a deep copy of this XmlObject. The returned object has the same type as the current object, and has all the content of the XML document underneath the current object. Note that any parts of the XML document above or outside this XmlObject are not copied. Note: The result object will be in the same synchronization domain as the source, and additional synchronization is required for concurent access. To use a different synchronization domain use setCopyUseNewSynchronizationDomain option when creating the original XmlObject.- Specified by:
copyin interfaceXmlObject- See Also:
XmlOptions.setCopyUseNewSynchronizationDomain(boolean)
-
valueEquals
public boolean valueEquals(XmlObject obj)
Description copied from interface:XmlObjectTrue if the xml values are equal. Two different objects (which are distinguished by equals(obj) == false) may of course have equal values (valueEquals(obj) == true).Usually this method can be treated as an ordinary equvalence relation, but actually it is not is not transitive. Here is a precise specification:
There are two categories of XML object: objects with a known instance type, and objects whose only known type is one of the ur-types (either AnyType or AnySimpleType). The first category is compared in terms of logical value spaces, and the second category is compared lexically.
Within each of these two categories, valueEquals is a well-behaved equivalence relation. However, when comparing an object of known type with an object with ur-type, the comparison is done by attempting to convert the lexical form of the ur-typed object into the other type, and then comparing the results. Ur-typed objects are therefore treated as lexical wildcards and may be equal to objects in different value spaces, even though the objects in different value spaces are not equal to each other.
For example, the anySimpleType value "1" will compare as an equalValue to the string "1", the float value "1.0", the double value "1.0", the decimal "1", and the GYear "1", even though all these objects will compare unequal to each other since they lie in different value spaces. Note: as of XMLBeans 2.2.1 only implemented for simple type values.
- Specified by:
valueEqualsin interfaceXmlObject
-
valueHashCode
public int valueHashCode()
- Specified by:
valueHashCodein interfaceXmlObject
-
compareTo
public int compareTo(java.lang.Object obj)
Description copied from interface:XmlObjectImpelements the Comparable interface by comparing two simple xml values based on their standard XML schema ordering. Throws a ClassCastException if no standard ordering applies, or if the two values are incomparable within a partial order.
-
compareValue
public int compareValue(XmlObject obj)
Description copied from interface:XmlObjectThis comparison method is similar to compareTo, but rather than throwing a ClassCastException when two values are incomparable, it returns the number 2. The result codes are -1 if this object is less than obj, 1 if this object is greater than obj, zero if the objects are equal, and 2 if the objects are incomparable.- Specified by:
compareValuein interfaceXmlObject
-
monitor
public java.lang.Object monitor()
Description copied from interface:XmlTokenSourceReturns the synchronization object for the document. If concurrent multithreaded access to a document is required, the access should should be protected by synchronizing on this monitor() object. There is one monitor per XML document tree.- Specified by:
monitorin interfaceXmlTokenSource
-
documentProperties
public XmlDocumentProperties documentProperties()
Description copied from interface:XmlTokenSourceReturns the XmlDocumentProperties object for the document this token source is associated with.- Specified by:
documentPropertiesin interfaceXmlTokenSource
-
newCursor
public XmlCursor newCursor()
Description copied from interface:XmlTokenSourceReturns a new XML cursor. A cursor provides random access to all the tokens in the XML data, plus the ability to extract strongly-typed XmlObjects for the data. If the data is not read-only, the XML cursor also allows modifications to the data. Using a cursor for the first time typically forces the XML document into memory.- Specified by:
newCursorin interfaceXmlTokenSource
-
newXMLInputStream
public XMLInputStream newXMLInputStream()
Deprecated.Deprecated by XMLStreamReader from STaX - jsr173 API.Description copied from interface:XmlTokenSourceReturns a new XmlInputStream. The stream starts at the current begin-tag or begin-document position and ends at the matching end-tag or end-document. This is a fail-fast stream, so if the underlying data is changed while the stream is being read, the stream throws a ConcurrentModificationException. Throws an IllegalStateException if the XmlTokenSource is not positioned at begin-tag or begin-document (e.g., if it is at an attribute).- Specified by:
newXMLInputStreamin interfaceXmlTokenSource
-
newXMLStreamReader
public javax.xml.stream.XMLStreamReader newXMLStreamReader()
Description copied from interface:XmlTokenSourceReturns a new XMLStreamReader. The stream starts at the current begin-tag or begin-document position and ends at the matching end-tag or end-document. This is a fail-fast stream, so if the underlying data is changed while the stream is being read, the stream throws a ConcurrentModificationException.- Specified by:
newXMLStreamReaderin interfaceXmlTokenSource
-
xmlText
public java.lang.String xmlText()
Description copied from interface:XmlTokenSourceReturns standard XML text.The text returned represents the document contents starting at the current begin-tag or begin-document and ending at the matching end-tag or end-document. This is same content as newReader, but it is returned as a single string.
Throws an IllegalStateException if the XmlTokenSource is not positioned at begin-tag or begin-document (e.g., if it is at an attribute).
Note that this method does not produce XML with the XML declaration, including the encoding information. To save the XML declaration with the XML, see
XmlTokenSource.save(OutputStream)orXmlTokenSource.save(OutputStream, XmlOptions).- Specified by:
xmlTextin interfaceXmlTokenSource
-
newInputStream
public java.io.InputStream newInputStream()
Description copied from interface:XmlTokenSourceReturns a new stream containing standard XML text, encoded according to the given encoding. The byte stream contains contents starting at the current begin-tag or begin-document and ending at the matching end-tag or end-document. The specified encoding is used and also emitted in a PI at the beginning of the stream. This is a fail-fast stream, so if the underlying data is changed while the stream is being read, the stream throws a ConcurrentModificationException. Throws an IllegalStateException if the XmlTokenSource is not positioned at begin-tag or begin-document (e.g., if it is at an attribute).- Specified by:
newInputStreamin interfaceXmlTokenSource
-
newReader
public java.io.Reader newReader()
Description copied from interface:XmlTokenSourceReturns a new character reader containing XML text. The contents of the reader represents the document contents starting at the current begin-tag or begin-document and ending at the matching end-tag or end-document. No encoding annotation will be made in the text itself. This is a fail-fast reader, so if the underlying data is changed while the reader is being read, the reader throws a ConcurrentModificationException. Throws an IllegalStateException if the XmlTokenSource is not positioned at begin-tag or begin-document (e.g., if it is at an attribute).- Specified by:
newReaderin interfaceXmlTokenSource
-
newDomNode
public org.w3c.dom.Node newDomNode()
Description copied from interface:XmlTokenSourceReturns a W3C DOM Node containing the XML represented by this source. This is a copy of the XML, it is not a live with the underlying store of this token source. If this is the document node, then a Document is returned, else a DocumentFragment is returned.- Specified by:
newDomNodein interfaceXmlTokenSource
-
getDomNode
public org.w3c.dom.Node getDomNode()
Description copied from interface:XmlTokenSourceReturns a W3C DOM Node containing the XML represented by this source. This is a live DOM node, not a copy. Any changes made through this node are immediately reflected in the document associated with this token source. Depending on the kind of token this XmlTokenSource represents, an appropriate node will be returned.- Specified by:
getDomNodein interfaceXmlTokenSource
-
save
public void save(org.xml.sax.ContentHandler ch, org.xml.sax.ext.LexicalHandler lh) throws org.xml.sax.SAXExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given SAX content and lexical handlers. Note that this method does not save the XML declaration, including the encoding information. To save the XML declaration with the XML, seeXmlTokenSource.save(OutputStream),XmlTokenSource.save(OutputStream, XmlOptions),XmlTokenSource.save(File)orXmlTokenSource.save(File, XmlOptions).- Specified by:
savein interfaceXmlTokenSource- Throws:
org.xml.sax.SAXException
-
save
public void save(java.io.File file) throws java.io.IOExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given File. This method will save the XML declaration, including encoding information, with the XML.- Specified by:
savein interfaceXmlTokenSource- Throws:
java.io.IOException
-
save
public void save(java.io.OutputStream os) throws java.io.IOExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given output stream. This method will save the XML declaration, including encoding information, with the XML.- Specified by:
savein interfaceXmlTokenSource- Throws:
java.io.IOException
-
save
public void save(java.io.Writer w) throws java.io.IOExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given output. Note that this method does not save the XML declaration, including the encoding information. To save the XML declaration with the XML, seeXmlTokenSource.save(OutputStream),XmlTokenSource.save(OutputStream, XmlOptions),XmlTokenSource.save(File)orXmlTokenSource.save(File, XmlOptions).- Specified by:
savein interfaceXmlTokenSource- Throws:
java.io.IOException
-
newXMLInputStream
public XMLInputStream newXMLInputStream(XmlOptions options)
Deprecated.Deprecated by XMLStreamReader from STaX - jsr173 API.Description copied from interface:XmlTokenSourceJust like newXMLInputStream() but with any of a number of options. Use the options parameter to specify the following:
To specify this Use this method The character encoding to use when converting the character data in the XML to bytess. XmlOptions.setCharacterEncoding(java.lang.String)Prefix-to-namespace mappings that should be assumed when saving this XML. This is useful when the resulting XML will be part of a larger XML document, ensuring that this inner document will take advantage of namespaces defined in the outer document. XmlOptions.setSaveImplicitNamespaces(java.util.Map)Suggested namespace prefixes to use when saving. Used only when a namespace attribute needs to be synthesized. XmlOptions.setSaveSuggestedPrefixes(java.util.Map)That namespace attributes should occur first in elements when the XML is saved. By default, they occur last. XmlOptions.setSaveNamespacesFirst()The XML should be pretty printed when saved. Note that this should only be used for debugging. XmlOptions.setSavePrettyPrint()The number of spaces to use when indenting for pretty printing. The default is 2. XmlOptions.setSavePrettyPrintIndent(int)The additional number of spaces indented from the left for pretty printed XML. XmlOptions.setSavePrettyPrintOffset(int)To minimize the number of namespace attributes generated for the saved XML. Note that this can reduce performance significantly. XmlOptions.setSaveAggresiveNamespaces()To reduce the size of the saved document by allowing the use of the default namespace. Note that this can potentially change the semantic meaning of the XML if unprefixed QNames are present as the value of an attribute or element. XmlOptions.setUseDefaultNamespace()To filter out processing instructions with the specified target name. XmlOptions.setSaveFilterProcinst(java.lang.String)Change the QName of the synthesized root element when saving. This replaces "xml-fragment" with "fragment" in the namespace http://www.openuri.org/fragment XmlOptions.setSaveUseOpenFrag()Saving should begin on the element's contents. XmlOptions.setSaveInner()Saving should begin on the element, rather than its contents. XmlOptions.setSaveOuter()To rename the document element, or to specify the document element for this XML. XmlOptions.setSaveSyntheticDocumentElement(javax.xml.namespace.QName)- Specified by:
newXMLInputStreamin interfaceXmlTokenSource- Parameters:
options- Any of the described options.- Returns:
- A new validating XMLInputStream.
- See Also:
XmlOptions
-
newXMLStreamReader
public javax.xml.stream.XMLStreamReader newXMLStreamReader(XmlOptions options)
Description copied from interface:XmlTokenSourceJust like newXMLInputStream() but with options. Options map may be null.- Specified by:
newXMLStreamReaderin interfaceXmlTokenSource- See Also:
XmlOptions
-
xmlText
public java.lang.String xmlText(XmlOptions options)
Description copied from interface:XmlTokenSourceJust like xmlText() but with options. Options map may be null.Note that this method does not produce XML with the XML declaration, including the encoding information. To save the XML declaration with the XML, see
XmlTokenSource.save(OutputStream)orXmlTokenSource.save(OutputStream, XmlOptions).- Specified by:
xmlTextin interfaceXmlTokenSource- See Also:
XmlOptions
-
newInputStream
public java.io.InputStream newInputStream(XmlOptions options)
Description copied from interface:XmlTokenSourceJust like newInputStream(String encoding) but with options. Options map may be null.- Specified by:
newInputStreamin interfaceXmlTokenSource- See Also:
XmlOptions
-
newReader
public java.io.Reader newReader(XmlOptions options)
Description copied from interface:XmlTokenSourceJust like newReader() but with options. Options map may be null.- Specified by:
newReaderin interfaceXmlTokenSource- See Also:
XmlOptions
-
newDomNode
public org.w3c.dom.Node newDomNode(XmlOptions options)
Description copied from interface:XmlTokenSourceJust like newDomNode() but with options. Options map may be null.- Specified by:
newDomNodein interfaceXmlTokenSource- See Also:
XmlOptions
-
save
public void save(org.xml.sax.ContentHandler ch, org.xml.sax.ext.LexicalHandler lh, XmlOptions options) throws org.xml.sax.SAXExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given SAX content and lexical handlers. Note that this method does not save the XML declaration, including the encoding information. To save the XML declaration with the XML, seeXmlTokenSource.save(OutputStream),XmlTokenSource.save(OutputStream, XmlOptions),XmlTokenSource.save(File)orXmlTokenSource.save(File, XmlOptions).- Specified by:
savein interfaceXmlTokenSource- Throws:
org.xml.sax.SAXException
-
save
public void save(java.io.File file, XmlOptions options) throws java.io.IOExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given File. This method will save the XML declaration, including encoding information, with the XML.- Specified by:
savein interfaceXmlTokenSource- Throws:
java.io.IOException
-
save
public void save(java.io.OutputStream os, XmlOptions options) throws java.io.IOExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given output stream. This method will save the XML declaration, including encoding information, with the XML.- Specified by:
savein interfaceXmlTokenSource- Throws:
java.io.IOException
-
save
public void save(java.io.Writer w, XmlOptions options) throws java.io.IOExceptionDescription copied from interface:XmlTokenSourceWrites the XML represented by this source to the given output. Note that this method does not save the XML declaration, including the encoding information. To save the XML declaration with the XML, seeXmlTokenSource.save(OutputStream),XmlTokenSource.save(OutputStream, XmlOptions),XmlTokenSource.save(File)orXmlTokenSource.save(File, XmlOptions).- Specified by:
savein interfaceXmlTokenSource- Throws:
java.io.IOException
-
instanceType
public SchemaType instanceType()
Description copied from interface:SimpleValueThe same as getSchemaType unless this is a union instance or nil value.For unions, this returns the non-union consituent type of this instance. This type may change if setters are called that cause the instance to change to another constituent type of the union.
For nil values, this returns null.
- Specified by:
instanceTypein interfaceSimpleValue
-
stringValue
public java.lang.String stringValue()
Deprecated.replaced withgetStringValue()Description copied from interface:SimpleValueReturns the value as aString. *- Specified by:
stringValuein interfaceSimpleValue
-
booleanValue
public boolean booleanValue()
Deprecated.replaced withgetBooleanValue()Description copied from interface:SimpleValueReturns the value as a boolean. *- Specified by:
booleanValuein interfaceSimpleValue
-
byteValue
public byte byteValue()
Deprecated.replaced withgetByteValue()Description copied from interface:SimpleValueReturns the value as a byte. *- Specified by:
byteValuein interfaceSimpleValue
-
shortValue
public short shortValue()
Deprecated.replaced withgetShortValue()Description copied from interface:SimpleValueReturns the value as a short. *- Specified by:
shortValuein interfaceSimpleValue
-
intValue
public int intValue()
Deprecated.replaced withgetIntValue()Description copied from interface:SimpleValueReturns the value as an int. *- Specified by:
intValuein interfaceSimpleValue
-
longValue
public long longValue()
Deprecated.replaced withgetLongValue()Description copied from interface:SimpleValueReturns the value as a long. *- Specified by:
longValuein interfaceSimpleValue
-
bigIntegerValue
public java.math.BigInteger bigIntegerValue()
Deprecated.replaced withgetBigIntegerValue()Description copied from interface:SimpleValueReturns the value as aBigInteger. *- Specified by:
bigIntegerValuein interfaceSimpleValue
-
bigDecimalValue
public java.math.BigDecimal bigDecimalValue()
Deprecated.replaced withgetBigDecimalValue()Description copied from interface:SimpleValueReturns the value as aBigDecimal. *- Specified by:
bigDecimalValuein interfaceSimpleValue
-
floatValue
public float floatValue()
Deprecated.replaced withgetFloatValue()Description copied from interface:SimpleValueReturns the value as a float. *- Specified by:
floatValuein interfaceSimpleValue
-
doubleValue
public double doubleValue()
Deprecated.replaced withgetDoubleValue()Description copied from interface:SimpleValueReturns the value as a double. *- Specified by:
doubleValuein interfaceSimpleValue
-
byteArrayValue
public byte[] byteArrayValue()
Deprecated.replaced withgetByteArrayValue()Description copied from interface:SimpleValueReturns the value as a byte array. *- Specified by:
byteArrayValuein interfaceSimpleValue
-
enumValue
public StringEnumAbstractBase enumValue()
Deprecated.replaced withgetEnumValue()Description copied from interface:SimpleValueReturns the value as aStringEnumAbstractBase. *- Specified by:
enumValuein interfaceSimpleValue
-
calendarValue
public java.util.Calendar calendarValue()
Deprecated.replaced withgetCalendarValue()Description copied from interface:SimpleValueReturns the value as aCalendar. *- Specified by:
calendarValuein interfaceSimpleValue
-
dateValue
public java.util.Date dateValue()
Deprecated.replaced withgetDateValue()Description copied from interface:SimpleValueReturns the value as aDate. *- Specified by:
dateValuein interfaceSimpleValue
-
gDateValue
public GDate gDateValue()
Deprecated.replaced withgetGDateValue()Description copied from interface:SimpleValueReturns the value as aGDate. *- Specified by:
gDateValuein interfaceSimpleValue
-
gDurationValue
public GDuration gDurationValue()
Deprecated.replaced withgetGDurationValue()Description copied from interface:SimpleValueReturns the value as aGDuration. *- Specified by:
gDurationValuein interfaceSimpleValue
-
qNameValue
public javax.xml.namespace.QName qNameValue()
Deprecated.replaced withgetQNameValue()Description copied from interface:SimpleValueReturns the value as aQName. *- Specified by:
qNameValuein interfaceSimpleValue
-
listValue
public java.util.List listValue()
Deprecated.replaced withgetListValue()Description copied from interface:SimpleValueReturns the value as aListof friendly Java objects (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration). *- Specified by:
listValuein interfaceSimpleValue
-
xlistValue
public java.util.List xlistValue()
Deprecated.replaced withgetListValue()Description copied from interface:SimpleValueReturns the value as aListof XmlAnySimpleType objects. *- Specified by:
xlistValuein interfaceSimpleValue
-
objectValue
public java.lang.Object objectValue()
Deprecated.replaced withgetObjectValue()Description copied from interface:SimpleValueReturns a union value as a its natural friendly Java object (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration). *- Specified by:
objectValuein interfaceSimpleValue
-
set
public void set(java.lang.String obj)
Deprecated.replaced withsetStringValue(java.lang.String)Description copied from interface:SimpleValueSets the value as aString. *- Specified by:
setin interfaceSimpleValue
-
set
public void set(boolean v)
Deprecated.replaced withsetBooleanValue(boolean)Description copied from interface:SimpleValueSets the value as a boolean. *- Specified by:
setin interfaceSimpleValue
-
set
public void set(byte v)
Deprecated.replaced withsetByteValue(byte)Description copied from interface:SimpleValueSets the value as a byte.- Specified by:
setin interfaceSimpleValue
-
set
public void set(short v)
Deprecated.replaced withsetShortValue(short)Description copied from interface:SimpleValueSets the value as a short.- Specified by:
setin interfaceSimpleValue
-
set
public void set(int v)
Deprecated.replaced withsetIntValue(int)Description copied from interface:SimpleValueSets the value as an int.- Specified by:
setin interfaceSimpleValue
-
set
public void set(long v)
Deprecated.replaced withsetLongValue(long)Description copied from interface:SimpleValueSets the value as a long.- Specified by:
setin interfaceSimpleValue
-
set
public void set(java.math.BigInteger obj)
Deprecated.replaced withsetBigIntegerValue(java.math.BigInteger)Description copied from interface:SimpleValueSets the value as aBigInteger.- Specified by:
setin interfaceSimpleValue
-
set
public void set(java.math.BigDecimal obj)
Deprecated.replaced withsetBigDecimalValue(java.math.BigDecimal)Description copied from interface:SimpleValueSets the value as aBigDecimal- Specified by:
setin interfaceSimpleValue
-
set
public void set(float v)
Deprecated.replaced withsetFloatValue(float)Description copied from interface:SimpleValueSets the value as a float.- Specified by:
setin interfaceSimpleValue
-
set
public void set(double v)
Deprecated.replaced withsetDoubleValue(double)Description copied from interface:SimpleValueSets the value as a double.- Specified by:
setin interfaceSimpleValue
-
set
public void set(byte[] obj)
Deprecated.replaced withsetByteArrayValue(byte[])Description copied from interface:SimpleValueSets the value as a byte array.- Specified by:
setin interfaceSimpleValue
-
set
public void set(StringEnumAbstractBase obj)
Deprecated.replaced withsetEnumValue(org.apache.xmlbeans.StringEnumAbstractBase)Description copied from interface:SimpleValueSets the value as aStringEnumAbstractBase.- Specified by:
setin interfaceSimpleValue
-
set
public void set(java.util.Calendar obj)
Deprecated.replaced withsetCalendarValue(java.util.Calendar)Description copied from interface:SimpleValueSets the value as aCalendar.- Specified by:
setin interfaceSimpleValue
-
set
public void set(java.util.Date obj)
Deprecated.replaced withsetDateValue(java.util.Date)Description copied from interface:SimpleValueSets the value as aDate.- Specified by:
setin interfaceSimpleValue
-
set
public void set(GDateSpecification obj)
Deprecated.replaced withsetGDateValue(org.apache.xmlbeans.GDate)Description copied from interface:SimpleValueSets the value as aGDate.- Specified by:
setin interfaceSimpleValue
-
set
public void set(GDurationSpecification obj)
Deprecated.replaced withsetGDurationValue(org.apache.xmlbeans.GDuration)Description copied from interface:SimpleValueSets the value as aGDuration.- Specified by:
setin interfaceSimpleValue
-
set
public void set(javax.xml.namespace.QName obj)
Deprecated.replaced withsetQNameValue(javax.xml.namespace.QName)Description copied from interface:SimpleValueSets the value as aQName.- Specified by:
setin interfaceSimpleValue
-
set
public void set(java.util.List obj)
Deprecated.replaced withsetListValue(java.util.List)Description copied from interface:SimpleValueSets the value as aList.- Specified by:
setin interfaceSimpleValue
-
getStringValue
public java.lang.String getStringValue()
Description copied from interface:SimpleValueReturns the value as aString.- Specified by:
getStringValuein interfaceSimpleValue
-
getBooleanValue
public boolean getBooleanValue()
Description copied from interface:SimpleValueReturns the value as a boolean.- Specified by:
getBooleanValuein interfaceSimpleValue
-
getByteValue
public byte getByteValue()
Description copied from interface:SimpleValueReturns the value as a byte.- Specified by:
getByteValuein interfaceSimpleValue
-
getShortValue
public short getShortValue()
Description copied from interface:SimpleValueReturns the value as a short.- Specified by:
getShortValuein interfaceSimpleValue
-
getIntValue
public int getIntValue()
Description copied from interface:SimpleValueReturns the value as an int.- Specified by:
getIntValuein interfaceSimpleValue
-
getLongValue
public long getLongValue()
Description copied from interface:SimpleValueReturns the value as a long.- Specified by:
getLongValuein interfaceSimpleValue
-
getBigIntegerValue
public java.math.BigInteger getBigIntegerValue()
Description copied from interface:SimpleValueReturns the value as aBigInteger.- Specified by:
getBigIntegerValuein interfaceSimpleValue
-
getBigDecimalValue
public java.math.BigDecimal getBigDecimalValue()
Description copied from interface:SimpleValueReturns the value as aBigDecimal.- Specified by:
getBigDecimalValuein interfaceSimpleValue
-
getFloatValue
public float getFloatValue()
Description copied from interface:SimpleValueReturns the value as a float.- Specified by:
getFloatValuein interfaceSimpleValue
-
getDoubleValue
public double getDoubleValue()
Description copied from interface:SimpleValueReturns the value as a double.- Specified by:
getDoubleValuein interfaceSimpleValue
-
getByteArrayValue
public byte[] getByteArrayValue()
Description copied from interface:SimpleValueReturns the value as a byte array.- Specified by:
getByteArrayValuein interfaceSimpleValue
-
getEnumValue
public StringEnumAbstractBase getEnumValue()
Description copied from interface:SimpleValueReturns the value as aStringEnumAbstractBase.- Specified by:
getEnumValuein interfaceSimpleValue
-
getCalendarValue
public java.util.Calendar getCalendarValue()
Description copied from interface:SimpleValueReturns the value as aCalendar.- Specified by:
getCalendarValuein interfaceSimpleValue
-
getDateValue
public java.util.Date getDateValue()
Description copied from interface:SimpleValueReturns the value as aDate.- Specified by:
getDateValuein interfaceSimpleValue
-
getGDateValue
public GDate getGDateValue()
Description copied from interface:SimpleValueReturns the value as aGDate.- Specified by:
getGDateValuein interfaceSimpleValue
-
getGDurationValue
public GDuration getGDurationValue()
Description copied from interface:SimpleValueReturns the value as aGDuration.- Specified by:
getGDurationValuein interfaceSimpleValue
-
getQNameValue
public javax.xml.namespace.QName getQNameValue()
Description copied from interface:SimpleValueReturns the value as aQName.- Specified by:
getQNameValuein interfaceSimpleValue
-
getListValue
public java.util.List getListValue()
Description copied from interface:SimpleValueReturns the value as aListof friendly Java objects (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration).- Specified by:
getListValuein interfaceSimpleValue
-
xgetListValue
public java.util.List xgetListValue()
Description copied from interface:SimpleValueReturns the value as aListof XmlAnySimpleType objects.- Specified by:
xgetListValuein interfaceSimpleValue
-
getObjectValue
public java.lang.Object getObjectValue()
Description copied from interface:SimpleValueReturns a union value as a its natural friendly Java object (String, Integer, Byte, Short, Long, BigInteger, Decimal, Float, Double, byte[], Calendar, GDuration).- Specified by:
getObjectValuein interfaceSimpleValue
-
setStringValue
public void setStringValue(java.lang.String obj)
Description copied from interface:SimpleValueSets the value as aString.- Specified by:
setStringValuein interfaceSimpleValue
-
setBooleanValue
public void setBooleanValue(boolean v)
Description copied from interface:SimpleValueSets the value as a boolean.- Specified by:
setBooleanValuein interfaceSimpleValue
-
setByteValue
public void setByteValue(byte v)
Description copied from interface:SimpleValueSets the value as a byte.- Specified by:
setByteValuein interfaceSimpleValue
-
setShortValue
public void setShortValue(short v)
Description copied from interface:SimpleValueSets the value as a short.- Specified by:
setShortValuein interfaceSimpleValue
-
setIntValue
public void setIntValue(int v)
Description copied from interface:SimpleValueSets the value as an int.- Specified by:
setIntValuein interfaceSimpleValue
-
setLongValue
public void setLongValue(long v)
Description copied from interface:SimpleValueSets the value as a long.- Specified by:
setLongValuein interfaceSimpleValue
-
setBigIntegerValue
public void setBigIntegerValue(java.math.BigInteger obj)
Description copied from interface:SimpleValueSets the value as aBigInteger.- Specified by:
setBigIntegerValuein interfaceSimpleValue
-
setBigDecimalValue
public void setBigDecimalValue(java.math.BigDecimal obj)
Description copied from interface:SimpleValueSets the value as aBigDecimal.- Specified by:
setBigDecimalValuein interfaceSimpleValue
-
setFloatValue
public void setFloatValue(float v)
Description copied from interface:SimpleValueSets the value as a float.- Specified by:
setFloatValuein interfaceSimpleValue
-
setDoubleValue
public void setDoubleValue(double v)
Description copied from interface:SimpleValueSets the value as a double.- Specified by:
setDoubleValuein interfaceSimpleValue
-
setByteArrayValue
public void setByteArrayValue(byte[] obj)
Description copied from interface:SimpleValueSets the value as a byte array.- Specified by:
setByteArrayValuein interfaceSimpleValue
-
setEnumValue
public void setEnumValue(StringEnumAbstractBase obj)
Description copied from interface:SimpleValueSets the value as aStringEnumAbstractBase.- Specified by:
setEnumValuein interfaceSimpleValue
-
setCalendarValue
public void setCalendarValue(java.util.Calendar obj)
Description copied from interface:SimpleValueSets the value as aCalendar.- Specified by:
setCalendarValuein interfaceSimpleValue
-
setDateValue
public void setDateValue(java.util.Date obj)
Description copied from interface:SimpleValueSets the value as aDate.- Specified by:
setDateValuein interfaceSimpleValue
-
setGDateValue
public void setGDateValue(GDate obj)
Description copied from interface:SimpleValueSets the value as aGDate.- Specified by:
setGDateValuein interfaceSimpleValue
-
setGDurationValue
public void setGDurationValue(GDuration obj)
Description copied from interface:SimpleValueSets the value as aGDuration.- Specified by:
setGDurationValuein interfaceSimpleValue
-
setQNameValue
public void setQNameValue(javax.xml.namespace.QName obj)
Description copied from interface:SimpleValueSets the value as aQName.- Specified by:
setQNameValuein interfaceSimpleValue
-
setListValue
public void setListValue(java.util.List obj)
Description copied from interface:SimpleValueSets the value as aList.- Specified by:
setListValuein interfaceSimpleValue
-
setObjectValue
public void setObjectValue(java.lang.Object obj)
Description copied from interface:SimpleValueSets the value as an arbitraryObject.- Specified by:
setObjectValuein interfaceSimpleValue
-
objectSet
public void objectSet(java.lang.Object obj)
Deprecated.replaced withsetObjectValue(java.lang.Object)Description copied from interface:SimpleValueSets the value as an arbitraryObject.- Specified by:
objectSetin interfaceSimpleValue
-
selectChildren
public XmlObject[] selectChildren(javax.xml.namespace.QName elementName)
Description copied from interface:XmlObjectSelects the contents of the children elements with the given name.- Specified by:
selectChildrenin interfaceXmlObject- Parameters:
elementName- The name of the elements to be selected.- Returns:
- Returns the contents of the selected elements.
-
selectChildren
public XmlObject[] selectChildren(java.lang.String elementUri, java.lang.String elementLocalName)
Description copied from interface:XmlObjectSelects the contents of the children elements with the given name.- Specified by:
selectChildrenin interfaceXmlObject- Parameters:
elementUri- The URI of the elements to be selected.elementLocalName- The local name of the elements to be selected.- Returns:
- Returns the contents of the selected elements.
-
selectChildren
public XmlObject[] selectChildren(QNameSet elementNameSet)
Description copied from interface:XmlObjectSelects the contents of the children elements that are contained in the elementNameSet.- Specified by:
selectChildrenin interfaceXmlObject- Parameters:
elementNameSet- Set of element names to be selected.- Returns:
- Returns the contents of the selected elements.
- See Also:
SchemaType.qnameSetForWildcardElements(),for creating sets of qnames
-
selectAttribute
public XmlObject selectAttribute(javax.xml.namespace.QName attributeName)
Description copied from interface:XmlObjectSelects the content of the attribute with the given name.- Specified by:
selectAttributein interfaceXmlObject- Parameters:
attributeName- The name of the attribute to be selected.- Returns:
- Returns the contents of the selected attribute.
-
selectAttribute
public XmlObject selectAttribute(java.lang.String attributeUri, java.lang.String attributeLocalName)
Description copied from interface:XmlObjectSelects the content of the attribute with the given name.- Specified by:
selectAttributein interfaceXmlObject- Parameters:
attributeUri- The URI of the attribute to be selected.attributeLocalName- The local name of the attribute to be selected.- Returns:
- Returns the content of the selected attribute.
-
selectAttributes
public XmlObject[] selectAttributes(QNameSet attributeNameSet)
Description copied from interface:XmlObjectSelects the contents of the attributes that are contained in the elementNameSet.- Specified by:
selectAttributesin interfaceXmlObject- Parameters:
attributeNameSet- Set of attribute names to be selected.- Returns:
- Returns the contents of the selected attributes.
- See Also:
SchemaType.qnameSetForWildcardAttributes(),for creating sets of qnames
-
-