ListTransducedAccessorImpl, TransducedAccessor_field_Boolean, TransducedAccessor_field_Byte, TransducedAccessor_field_Double, TransducedAccessor_field_Float, TransducedAccessor_field_Integer, TransducedAccessor_field_Long, TransducedAccessor_field_Short, TransducedAccessor_method_Boolean, TransducedAccessor_method_Byte, TransducedAccessor_method_Double, TransducedAccessor_method_Float, TransducedAccessor_method_Integer, TransducedAccessor_method_Long, TransducedAccessor_method_Shortpublic abstract class DefaultTransducedAccessor<T> extends TransducedAccessor<T>
TransducedAccessor that prints to String.
The print method that works for String determines the dispatching
of the writeText(XMLSerializer,Object,String) and
writeLeafElement(XMLSerializer, Name, Object, String) methods,
so those are implemented here.
TransducedAccessor.CompositeTransducedAccessorImpl<BeanT,ValueT>| Constructor | Description |
|---|---|
DefaultTransducedAccessor() |
| Modifier and Type | Method | Description |
|---|---|---|
abstract String |
print(T o) |
Prints the responsible field of the given bean to the writer.
|
void |
writeLeafElement(XMLSerializer w,
Name tagName,
T o,
String fieldName) |
Convenience method to write the value as a text inside an element
without any attributes.
|
void |
writeText(XMLSerializer w,
T o,
String fieldName) |
Invokes one of the
XMLSerializer.text(String, String) method
with the representation of data bested suited for this transduced accessor. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitdeclareNamespace, get, hasValue, parse, useNamespacepublic abstract String print(T o) throws AccessorException, SAXException
TransducedAccessor
Use XMLSerializer.getInstance() to access to the namespace bindings
print in class TransducedAccessor<T>AccessorExceptionSAXExceptionpublic void writeLeafElement(XMLSerializer w, Name tagName, T o, String fieldName) throws SAXException, AccessorException, IOException, XMLStreamException
TransducedAccessorThe callee assumes that there's an associated value in the field. No @xsi:type handling is expected.
writeLeafElement in class TransducedAccessor<T>SAXExceptionAccessorExceptionIOExceptionXMLStreamExceptionpublic void writeText(XMLSerializer w, T o, String fieldName) throws AccessorException, SAXException, IOException, XMLStreamException
TransducedAccessorXMLSerializer.text(String, String) method
with the representation of data bested suited for this transduced accessor.writeText in class TransducedAccessor<T>AccessorExceptionSAXExceptionIOExceptionXMLStreamExceptionCopyright © 2018 Oracle Corporation. All rights reserved.