net.sf.genuine.tools
Class XML

java.lang.Object
  extended bynet.sf.genuine.tools.XML

public class XML
extends java.lang.Object

Helper methods for XML processing with JDOM

Author:
Tim Wellhausen

Constructor Summary
XML()
           
 
Method Summary
static java.util.Map createPropertiesMap(org.jdom.Element propertiesElement)
          Creates a hash map containing properities (key/value pairs) and property sets (key/set of values pairs) from the given XML "properties" element.
static org.jdom.Document loadDocumentFromClasspath(java.lang.String filename)
          Loads the XML document refered to by the given filename and returns a Document instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XML

public XML()
Method Detail

loadDocumentFromClasspath

public static org.jdom.Document loadDocumentFromClasspath(java.lang.String filename)
                                                   throws OperationFailedException
Loads the XML document refered to by the given filename and returns a Document instance. The given file must is loaded using a classloader. The file must therefore be accessible on the classpath.

Throws:
OperationFailedException

createPropertiesMap

public static java.util.Map createPropertiesMap(org.jdom.Element propertiesElement)
Creates a hash map containing properities (key/value pairs) and property sets (key/set of values pairs) from the given XML "properties" element.