| Modifier and Type | Field and Description |
|---|---|
| private final DocumentBuilder | |
| private final TransformerFactory |
| Access | Constructor and Description |
|---|---|
| public | |
| public | XmpSerializer(TransformerFactory
transformer factory to be used transformerFactory, DocumentBuilderFactory document builder factory to be used documentBuilderFactory)Constructor to be used if other factories than the default ones are needed. |
| Modifier and Type | Method and Description |
|---|---|
| protected Element | |
| private void | |
| private List | Returns: the list of attributed for serializingthe property that needs to be inspected property)Normalize the list of attributes. |
| private void | save(Node
The XML document to save. doc, OutputStream The stream to save the document to. outStream, String The encoding to save the file as. encoding)Save the XML document to an output stream. |
| public void | |
| public void | serializeFields(Document doc, Element parent, List<AbstractField> fields, String resourceNS, String prefix, boolean wrapWithProperty)
|
| protected Element |
| documentBuilder | back to summary |
|---|---|
| private final DocumentBuilder documentBuilder | |
| transformerFactory | back to summary |
|---|---|
| private final TransformerFactory transformerFactory | |
| XmpSerializer | back to summary |
|---|---|
| public XmpSerializer() Default constructor.
| |
| XmpSerializer | back to summary |
|---|---|
| public XmpSerializer(TransformerFactory transformerFactory, DocumentBuilderFactory documentBuilderFactory) Constructor to be used if other factories than the default ones are needed.
| |
| createRdfElement | back to summary |
|---|---|
| protected Element createRdfElement(Document doc, XMPMetadata metadata, boolean withXpacket) | |
| fillElementWithAttributes | back to summary |
|---|---|
| private void fillElementWithAttributes(Element target, AbstractComplexProperty property) | |
| normalizeAttributes | back to summary |
|---|---|
| private List Normalize the list of attributes. Attributes which match a schema property are serialized as child elements so only return the ones which do not match a schema property
| |
| save | back to summary |
|---|---|
| private void save(Node doc, OutputStream outStream, String encoding) throws TransformerException Save the XML document to an output stream.
| |
| serialize | back to summary |
|---|---|
| public void serialize(XMPMetadata metadata, OutputStream os, boolean withXpacket) throws TransformerException | |
| serializeFields | back to summary |
|---|---|
| public void serializeFields(Document doc, Element parent, List<AbstractField> fields, String resourceNS, String prefix, boolean wrapWithProperty) | |
| serializeSchema | back to summary |
|---|---|
| protected Element serializeSchema(Document doc, XMPSchema schema) | |