org.sblim.cimclient.internal.cimxml

Class CimXmlSerializer

public class CimXmlSerializer extends Object

Class CimXmlSerializer implements a XML serializer for DOM documents that is specialized for CIM-XML. It might not be used as a general purpose serializer since it doesn't support any DOM or XML features not required by CIM-XML.
Method Summary
static voidserialize(OutputStream pOS, Document pDoc, boolean pPretty)
Serializes a given DOM document as (CIM-)XML to a given output stream.
static voidserialize(OutputStream pOS, Node pNode, boolean pPretty)
Serializes a given DOM node as (CIM-)XML to a given output stream

Method Detail

serialize

public static void serialize(OutputStream pOS, Document pDoc, boolean pPretty)
Serializes a given DOM document as (CIM-)XML to a given output stream. The method writes first <?xml version="1.0" encoding="UTF-8"?> and then serializes the document node. If you want to suppress this header just call CimXmlSerializer on the document node.

Parameters: pOS The output stream pDoc The document pPretty If true the XML is nicely wrapped and indented, otherwise it's all in one line

Throws: IOException Whenever something goes wrong

serialize

public static void serialize(OutputStream pOS, Node pNode, boolean pPretty)
Serializes a given DOM node as (CIM-)XML to a given output stream

Parameters: pOS The output stream pNode The node pPretty If true the XML is nicely wrapped and indented, otherwise it's all in one line

Throws: IOException Whenever something goes wrong

Copyright © 2005, 2010 IBM Corporation. All Rights Reserved.