Class XMLTemplateSerializer
java.lang.Object
org.nuxeo.template.serializer.executors.XMLTemplateSerializer
- All Implemented Interfaces:
TemplateSerializer
TemplateInput
parameters are stored in the DocumentModel
as a single String Property via XML
Serialization. This class contains the Serialization/Deserialization logic.- Since:
- 11.1
- Author:
- Tiry ([email protected]), bjalon ([email protected])
-
Nested Class Summary
Modifier and TypeClassDescriptionprotected static class
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptiondeserialize
(String xml) Transform String to a List of TemplateInput.protected void
doSerialization
(org.dom4j.Element field, TemplateInput param) protected TemplateInput
extractTemplateInputFromXMLNode
(org.dom4j.Element node) protected Boolean
getIsAutoloopFromXMLNode
(org.dom4j.Element elem) protected Boolean
getIsReadonlyFromXMLNode
(org.dom4j.Element elem) protected String
getNameFromXMLNode
(org.dom4j.Element elem) protected InputType
getTypeFromXMLNode
(org.dom4j.Element elem) serialize
(List<TemplateInput> params) Transform the List of TemplateInput to String.
-
Field Details
-
XML_NAMESPACE
- See Also:
-
XML_NAMESPACE_PREFIX
- See Also:
-
ns
public static final org.dom4j.Namespace ns -
fieldsTag
public static final org.dom4j.QName fieldsTag -
fieldTag
public static final org.dom4j.QName fieldTag -
DATE_FORMAT
- See Also:
-
-
Constructor Details
-
XMLTemplateSerializer
public XMLTemplateSerializer()
-
-
Method Details
-
deserialize
Description copied from interface:TemplateSerializer
Transform String to a List of TemplateInput. TemplateInput represent a field that will be finally added into the context of the file rendition. Please for more information look the documentation ofTemplateSerializerService
- Specified by:
deserialize
in interfaceTemplateSerializer
- Parameters:
xml
- String containing a list of fields' description serialized- Returns:
- the serialized content
-
extractTemplateInputFromXMLNode
-
getIsReadonlyFromXMLNode
-
getIsAutoloopFromXMLNode
-
getNameFromXMLNode
-
getTypeFromXMLNode
-
serialize
Description copied from interface:TemplateSerializer
Transform the List of TemplateInput to String. Used to store a rendition context in the Document TemplateBased. Please for more information look the documentation ofTemplateSerializerService
- Specified by:
serialize
in interfaceTemplateSerializer
-
doSerialization
-