|
Javolution 6.0.0 java
|
Public Member Functions | |
| XMLStreamWriter | getStreamWriter () |
| void | add (Object obj) throws XMLStreamException |
| void | add (Object obj, String name) throws XMLStreamException |
| void | add (Object obj, String localName, String uri) throws XMLStreamException |
| void | addText (CharSequence text) throws XMLStreamException |
| void | addText (String text) throws XMLStreamException |
| void | setAttribute (String name, CharSequence value) throws XMLStreamException |
| void | setAttribute (String name, String value) throws XMLStreamException |
| void | setAttribute (String name, boolean value) throws XMLStreamException |
| void | setAttribute (String name, char value) throws XMLStreamException |
| void | setAttribute (String name, byte value) throws XMLStreamException |
| void | setAttribute (String name, short value) throws XMLStreamException |
| void | setAttribute (String name, int value) throws XMLStreamException |
| void | setAttribute (String name, long value) throws XMLStreamException |
| void | setAttribute (String name, float value) throws XMLStreamException |
| void | setAttribute (String name, double value) throws XMLStreamException |
| void | setAttribute (String name, Object value) throws XMLStreamException |
Package Functions | |
| OutputElement () | |
| public< T > void | add (T obj, String name, Class< T > cls) throws XMLStreamException |
| public< T > void | add (T obj, String localName, String uri, Class< T > cls) throws XMLStreamException |
| void | setBinding (XMLBinding xmlBinding) |
| void | setReferenceResolver (XMLReferenceResolver xmlReferenceResolver) |
| void | reset () |
Package Attributes | |
| final XMLStreamWriterImpl | _writer = new XMLStreamWriterImpl() |
Private Member Functions | |
| boolean | writeReference (Object obj) throws XMLStreamException |
Private Attributes | |
| XMLBinding | _binding |
| XMLReferenceResolver | _referenceResolver |
| TextBuilder | _tmpTextBuilder = new TextBuilder() |
This class represents an output XML element (marshalling).
Definition at line 622 of file XMLFormat.java.
|
package |
| void javolution.xml.XMLFormat< T >.OutputElement.add | ( | Object | obj | ) | throws XMLStreamException |
Adds the specified object or null as an anonymous nested element of unknown type.
| obj | the object added as nested element or null. |
Definition at line 662 of file XMLFormat.java.
References javolution.xml.XMLFormat< T >.isReferenceable(), javolution.xml.XMLFormat< T >.NULL, javolution.xml.XMLFormat< T >.write(), javolution.xml.XMLBinding.writeClass(), javolution.xml.internal.stream.XMLStreamWriterImpl.writeEmptyElement(), and javolution.xml.internal.stream.XMLStreamWriterImpl.writeEndElement().
| void javolution.xml.XMLFormat< T >.OutputElement.add | ( | Object | obj, |
| String | localName, | ||
| String | uri | ||
| ) | throws XMLStreamException |
Adds the specified object as a fully qualified nested element of unknown type (null objects are ignored). The nested XML element contains a class attribute identifying the object type.
| obj | the object added as nested element or null. |
| localName | the local name of the nested element. |
| uri | the namespace URI of the nested element. |
Definition at line 722 of file XMLFormat.java.
References javolution.xml.XMLFormat< T >.isReferenceable(), javolution.xml.XMLFormat< T >.write(), javolution.xml.XMLBinding.writeClass(), javolution.xml.internal.stream.XMLStreamWriterImpl.writeEndElement(), and javolution.xml.internal.stream.XMLStreamWriterImpl.writeStartElement().
| void javolution.xml.XMLFormat< T >.OutputElement.add | ( | Object | obj, |
| String | name | ||
| ) | throws XMLStreamException |
Adds the specified object as a named nested element of unknown type (null objects are ignored). The nested XML element contains a class attribute identifying the object type.
| obj | the object added as nested element or null. |
| name | the name of the nested element. |
Definition at line 691 of file XMLFormat.java.
References javolution.xml.XMLFormat< T >.isReferenceable(), javolution.xml.XMLFormat< T >.write(), javolution.xml.XMLBinding.writeClass(), javolution.xml.internal.stream.XMLStreamWriterImpl.writeEndElement(), and javolution.xml.internal.stream.XMLStreamWriterImpl.writeStartElement().
|
package |
Adds the specified object as a fully qualified nested element of specified actual type (null objects are ignored). The nested XML element does not contain any class attribute.
| obj | the object added as nested element or null. |
| localName | the local name of the nested element. |
| uri | the namespace URI of the nested element. |
| cls | the class identifying the format of the specified object. |
Definition at line 780 of file XMLFormat.java.
References javolution.xml.XMLBinding.getFormat(), javolution.xml.XMLFormat< T >.isReferenceable(), javolution.xml.XMLFormat< T >.write(), javolution.xml.internal.stream.XMLStreamWriterImpl.writeEndElement(), and javolution.xml.internal.stream.XMLStreamWriterImpl.writeStartElement().
|
package |
Adds the specified object as a named nested element of specified
actual type (null objects are ignored). The nested XML element does not contain any class attribute.
| obj | the object added as nested element or null. |
| name | the name of the nested element. |
| cls | the class identifying the format of the specified object. |
Definition at line 753 of file XMLFormat.java.
References javolution.xml.XMLBinding.getFormat(), javolution.xml.XMLFormat< T >.isReferenceable(), javolution.xml.XMLFormat< T >.write(), javolution.xml.internal.stream.XMLStreamWriterImpl.writeEndElement(), and javolution.xml.internal.stream.XMLStreamWriterImpl.writeStartElement().
| void javolution.xml.XMLFormat< T >.OutputElement.addText | ( | CharSequence | text | ) | throws XMLStreamException |
Adds the content of a text-only element (equivalent to getStreamWriter().writeCharacters(text)).
| text | the element text content or an empty sequence if none. |
Definition at line 813 of file XMLFormat.java.
References javolution.xml.internal.stream.XMLStreamWriterImpl.writeCharacters().
| void javolution.xml.XMLFormat< T >.OutputElement.addText | ( | String | text | ) | throws XMLStreamException |
Equivalent to addText(CharSequence) (for J2ME compatibility).
| text | the element text content or an empty sequence if none. |
Definition at line 823 of file XMLFormat.java.
References javolution.xml.internal.stream.XMLStreamWriterImpl.writeCharacters().
| XMLStreamWriter javolution.xml.XMLFormat< T >.OutputElement.getStreamWriter | ( | ) |
Returns the StAX-like stream writer (provides complete control over the marshalling process).
Definition at line 652 of file XMLFormat.java.
|
package |
Definition at line 972 of file XMLFormat.java.
References javolution.xml.XMLBinding.DEFAULT, javolution.xml.internal.stream.XMLStreamWriterImpl.reset(), javolution.xml.internal.stream.XMLStreamWriterImpl.setAutomaticEmptyElements(), and javolution.xml.internal.stream.XMLStreamWriterImpl.setRepairingNamespaces().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| boolean | value | ||
| ) | throws XMLStreamException |
Sets the specified boolean attribute.
| name | the attribute name. |
| value | the boolean value for the specified attribute. |
Definition at line 861 of file XMLFormat.java.
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| byte | value | ||
| ) | throws XMLStreamException |
Sets the specified byte attribute.
| name | the attribute name. |
| value | the byte value for the specified attribute. |
Definition at line 886 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| char | value | ||
| ) | throws XMLStreamException |
Sets the specified char attribute.
| name | the attribute name. |
| value | the char value for the specified attribute. |
Definition at line 874 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| CharSequence | value | ||
| ) | throws XMLStreamException |
Sets the specified CharSequence attribute (null values are ignored).
| name | the attribute name. |
| value | the attribute value or null. |
Definition at line 834 of file XMLFormat.java.
References javolution.xml.internal.stream.XMLStreamWriterImpl.writeAttribute().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| double | value | ||
| ) | throws XMLStreamException |
Sets the specified double attribute.
| name | the attribute name. |
| value | the double value for the specified attribute. |
Definition at line 941 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| float | value | ||
| ) | throws XMLStreamException |
Sets the specified float attribute.
| name | the attribute name. |
| value | the float value for the specified attribute. |
Definition at line 930 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| int | value | ||
| ) | throws XMLStreamException |
Sets the specified int attribute.
| name | the attribute name. |
| value | the int value for the specified attribute. |
Definition at line 908 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| long | value | ||
| ) | throws XMLStreamException |
Sets the specified long attribute.
| name | the attribute name. |
| value | the long value for the specified attribute. |
Definition at line 919 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| Object | value | ||
| ) | throws XMLStreamException |
Sets the specified attribute using its associated TextFormat.
| name | the name of the attribute. |
| value | the value for the specified attribute or null in which case the attribute is not set. |
Definition at line 954 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| short | value | ||
| ) | throws XMLStreamException |
Sets the specified short attribute.
| name | the attribute name. |
| value | the short value for the specified attribute. |
Definition at line 897 of file XMLFormat.java.
References javolution.text.TextBuilder.append(), and javolution.text.TextBuilder.clear().
| void javolution.xml.XMLFormat< T >.OutputElement.setAttribute | ( | String | name, |
| String | value | ||
| ) | throws XMLStreamException |
Sets the specified String attribute (null values are ignored).
| name | the attribute name. |
| value | the attribute value. |
Definition at line 848 of file XMLFormat.java.
References javolution.xml.internal.stream.XMLStreamWriterImpl.writeAttribute().
|
package |
Definition at line 962 of file XMLFormat.java.
|
package |
Definition at line 967 of file XMLFormat.java.
|
private |
Definition at line 798 of file XMLFormat.java.
References javolution.xml.internal.stream.XMLStreamWriterImpl.writeEndElement(), and javolution.xml.XMLReferenceResolver.writeReference().
|
private |
Holds the XML binding.
Definition at line 632 of file XMLFormat.java.
|
private |
Holds the reference resolver.
Definition at line 637 of file XMLFormat.java.
|
private |
Definition at line 866 of file XMLFormat.java.
|
package |
Holds the stream writer.
Definition at line 627 of file XMLFormat.java.