| java.lang.Object com.completex.objective.components.persistency.io.xml.impl.XmlDomStream com.completex.objective.components.persistency.io.xml.impl.XmlPersistentObjectOutputStream
XmlPersistentObjectOutputStream | public class XmlPersistentObjectOutputStream extends XmlDomStream implements PoObjectOutput,XmlStreamTags(Code) | | Implementation of PoObjectoutput interface. The stream is not thread safe.
Only PersistentObjects, their Collections and basic Java types including the primitives,
which are assumed "known", are serialized in readable format. All other ones are serialized as "binaries".
If the generated persistent object implements java.util.Extenalizable interface then all
extras in the inherited objects are to be written in PersistentObject.writeExternalDescendant(ObjectOutput out)
and read reapecitivey in PersistentObject.readExternalDescendant(ObjectInput in)
method.
References are guaranteed to be preserved for all "known" objects (see above) and not for "binaries".
Even though for the binary objects of the 1st level the references will be preserved, for the "internal" objects (
binaries inside binaries) references from/to external object will not be preserved.
author: Gennady Krizhevsky |
Inner Class :class XmlValueStruct | |
Method Summary | |
protected void | addNull(Element extTypeNode) | protected void | addTextValue(Element vElement, String stringValue) | public void | close() | protected Document | createDocument(DocumentBuilder builder) | protected Element | createElement(Element parentElement, String tagName) | protected Element | createElement(String tagName) | public void | flush() | public void | flush(OutputStream outputStream) | protected void | init() | public boolean | isUseNames() | public boolean | isUseReferences() | public void | setPreserveOriginalValues(boolean preserveOriginalValues) | public void | setUseNames(boolean useNames) | public void | setUseNamesJavaStyle(boolean useNamesJavaStyle) | public void | setUseReferences(boolean useReferences) | protected void | setupRootElement() | protected boolean | skipField(Record record, String stringValue, String stringOrigValue) | protected ValueStringResult | value2string(Element element, ColumnType type, Object value) | protected ValueStringResult | value2string(Object value) | public void | write(int b) | public void | write(byte b) | public void | write(byte b, int off, int len) | public void | writeBoolean(boolean v) | public void | writeByte(int v) | public void | writeBytes(String s) | public void | writeChar(int v) | public void | writeChars(String s) | protected void | writeCollection(Element complexElement, Collection collection) | protected void | writeCollectionElements(Object result, Element collectionElements) | protected void | writeComplexChildren(Element pElement, PersistentObject persistent) | protected void | writeCompoundChildren(Element pElement, PersistentObject persistent) | protected void | writeCompoundKey(Element keyNode, CompoundNaturalKeyImpl naturalKey) | protected void | writeDirty(PersistentEntry entry, Element fElement) | public void | writeDouble(double v) | protected void | writeExtType(Element parentElement, Object obj, Class primitiveClass) | protected void | writeExternalDescendant(Element poNode, PersistentObject persistent) | protected void | writeField(int index, Record record, Element rElement) | protected void | writeField(int index, Record record, Element rElement, XmlValueStruct valueStruct) | public void | writeFloat(float v) | public void | writeInt(int v) | protected void | writeKeyValue(Element keyNode, Object key) | protected boolean | writeLink(Link link, Element cpxElements) | public void | writeLong(long v) | public void | writeObject(Object obj) Only PersistentObjects, their Collections and basic Java types including the primitives are serialized
in readable format. | protected void | writeObject(Element parentElement, Object obj) | protected void | writePersistentObject(Element parentElement, PersistentObject persistent) | protected void | writeRecord(Element pElement, PersistentObject persistent) | protected boolean | writeReferenceAttrs(Element vElement, Object value) | public void | writeShort(int v) | protected void | writeSimpleKey(Element keyNode, SimpleNaturalKeyImpl naturalKey) | protected void | writeSimpleKeyValue(Element valuesNode, Object value) | protected void | writeTracer(Element collectionNode, Collection collection) | protected void | writeTracerEntry(Element tracerNode, CollectionTracer.ModifiedEntry modifiedEntry) | public void | writeUTF(String str) | protected void | writeValue(XmlValueStruct valueStruct, Element fElement) | protected void | writeValue(String tagName, Object value, ValueStringResult result, Element fElement) |
init | protected void init()(Code) | | |
isUseNames | public boolean isUseNames()(Code) | | Return true if persistent object column names are to be shown
true if persistent object column names are to be shown |
isUseReferences | public boolean isUseReferences()(Code) | | |
setUseNames | public void setUseNames(boolean useNames)(Code) | | Set true if persistent object column names are to be shown
Parameters: useNames - true if persistent object column names are to be shown |
setUseNamesJavaStyle | public void setUseNamesJavaStyle(boolean useNamesJavaStyle)(Code) | | Set true if persistent object column names are to be shown in JavaBeans style
Parameters: useNamesJavaStyle - true if persistent object column names are to be shown in JavaBeans style |
setUseReferences | public void setUseReferences(boolean useReferences)(Code) | | |
setupRootElement | protected void setupRootElement()(Code) | | |
writeField | protected void writeField(int index, Record record, Element rElement, XmlValueStruct valueStruct)(Code) | | |
writeValue | protected void writeValue(XmlValueStruct valueStruct, Element fElement)(Code) | | |
|
|