Package org.ametys.plugins.contentio
Class ContentImporterHelper
java.lang.Object
org.ametys.plugins.contentio.ContentImporterHelper
Helper to import contents.
- 
Method Summary
Modifier and TypeMethodDescriptionstatic StringserializeNode(Node node) Serialize a XML node as a String, with XML declaration and without indentation.static StringserializeNode(Node node, boolean indent) Serialize a XML node as a String, with XML declaration.static StringserializeNode(Node node, boolean indent, boolean omitXmlDeclaration) Serialize a XML node as a String.static StringtextToDocbook(String[] lines) Transform text to docbook syntaxe 
- 
Method Details
- 
textToDocbook
Transform text to docbook syntaxe- Parameters:
 lines- The paragraphs to transform- Returns:
 - the docbook text
 
 - 
serializeNode
Serialize a XML node as a String, with XML declaration and without indentation.- Parameters:
 node- the node.- Returns:
 - the XML string.
 - Throws:
 TransformerException- if an error occurs.
 - 
serializeNode
Serialize a XML node as a String, with XML declaration.- Parameters:
 node- the node.indent- true to indent the result, false otherwise.- Returns:
 - the XML string.
 - Throws:
 TransformerException- if an error occurs.
 - 
serializeNode
public static String serializeNode(Node node, boolean indent, boolean omitXmlDeclaration) throws TransformerException Serialize a XML node as a String.- Parameters:
 node- the node.indent- true to indent the result, false otherwise.omitXmlDeclaration- true to omit XML declaration, false otherwise.- Returns:
 - the XML string.
 - Throws:
 TransformerException- if an error occurs.
 
 -