uk.ac.soton.itinnovation.registry.icomponent.util
Class XmlHelperSupport

java.lang.Object
  extended by uk.ac.soton.itinnovation.registry.icomponent.util.XmlHelperSupport

public final class XmlHelperSupport
extends Object

This class provides general helper functionality for processing XML.

Author:
Uwe Radetzki

Constructor Summary
XmlHelperSupport()
           
 
Method Summary
static Document createDocument(Element domElement)
          Creates a DOM document from a DOM element.
static Document createDocument(File file)
          Creates a DOM document from a file.
static Document createDocument(InputStream stream)
          Creates a document from an input stream.
static Document createDocument(String xmlString)
          Creates a DOM document from an XML string.
static org.jdom.Document createJDomDocument(Document domDocument)
          Transfer a DOM document into a JDOM document.
static org.jdom.Document createJDomDocument(Element domElement)
          Creates a JDOM docment from a DOM element.
static String documentToStringContent(Document domDocument)
          Creates the string content of a document.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XmlHelperSupport

public XmlHelperSupport()
Method Detail

createJDomDocument

public static final org.jdom.Document createJDomDocument(Element domElement)
Creates a JDOM docment from a DOM element.

Parameters:
domElement -

createJDomDocument

public static final org.jdom.Document createJDomDocument(Document domDocument)
Transfer a DOM document into a JDOM document.

Parameters:
domDocument -

createDocument

public static final Document createDocument(Element domElement)
Creates a DOM document from a DOM element.

Parameters:
domElement - DOM element
Returns:
new DOM document, otherwise null

createDocument

public static final Document createDocument(String xmlString)
Creates a DOM document from an XML string.

Parameters:
xmlString - XML string
Returns:
new DOM document, otherwise null

createDocument

public static final Document createDocument(File file)
Creates a DOM document from a file.

Parameters:
file - file
Returns:
new DOM document, otherwise null

createDocument

public static final Document createDocument(InputStream stream)
Creates a document from an input stream.

Parameters:
stream -
Returns:
document

documentToStringContent

public static final String documentToStringContent(Document domDocument)
Creates the string content of a document.

Parameters:
domDocument -


Copyright © 2001-2007 University of Southampton IT Innovation Centre. All Rights Reserved.