net.sf.statsvn.util
Class XMLUtil

java.lang.Object
  extended by net.sf.statsvn.util.XMLUtil

public final class XMLUtil
extends java.lang.Object

Utilities class to faciliate XML management.

 

Method Summary
static java.util.Date offsetDateFromGMT(java.util.Date date)
          This method converts from GMT to local timezone
static java.util.Date parseXsdDateTime(java.lang.String sDateTime)
          For some reason, can't find this utility method in the java framework.
static void writeXmlFile(org.w3c.dom.Document doc, java.lang.String filename)
          This method writes a DOM document to a file
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

parseXsdDateTime

public static java.util.Date parseXsdDateTime(java.lang.String sDateTime)
                                       throws java.text.ParseException
For some reason, can't find this utility method in the java framework.

Throws:
java.text.ParseException
Parameters:
sDateTime - an xsd:dateTime string
Returns:
an equivalent java.util.Date

offsetDateFromGMT

public static java.util.Date offsetDateFromGMT(java.util.Date date)
This method converts from GMT to local timezone

Parameters:
date - date in GMT timezone
Returns:
the date in local timezone

writeXmlFile

public static void writeXmlFile(org.w3c.dom.Document doc,
                                java.lang.String filename)
This method writes a DOM document to a file

Parameters:
doc - DOM document.
filename - the target file.