org.freehep.xml.io
Class XMLIOFileManager
java.lang.Object
org.freehep.xml.io.XMLIOStreamManager
org.freehep.xml.io.XMLIOFileManager
public class XMLIOFileManager
- extends XMLIOStreamManager
Class XMLIOFileManager deals with xml files.
- Version:
- 1.0
- Author:
- turri
Method Summary |
org.jdom.Element |
getRootElement()
After opening the input file, converts the text in xml format
and returns the main root Element |
boolean |
isXMLFileZipped()
|
void |
saveRootElement(org.jdom.Element rootEl)
Write to the output Stream performing an xml to text conversion |
void |
saveRootElement(org.jdom.Element rootEl,
String docName,
String sysId)
Write the output file performing an xml to text conversion |
void |
setXMLFileZipped(boolean isZipped)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XMLIOFileManager
public XMLIOFileManager(String fileName)
getRootElement
public org.jdom.Element getRootElement()
throws org.jdom.JDOMException,
IOException
- After opening the input file, converts the text in xml format
and returns the main root Element
- Overrides:
getRootElement
in class XMLIOStreamManager
- Returns:
- the jdom main Element or
null
if something
went wrong in the text to xml conversion (the trace is
printed).
- Throws:
org.jdom.JDOMException
- from XMLIOStreamManager
IOException
- from XMLIOStreamManager- See Also:
XMLIOStreamManager.getRootElement()
,
XMLIOStreamManager.getRootElement()
saveRootElement
public void saveRootElement(org.jdom.Element rootEl,
String docName,
String sysId)
throws IOException
- Write the output file performing an xml to text conversion
- Parameters:
rootEl
- is the root Element that gets converted
to text and dumped in the output file.
- Throws:
IOException
- from XMLIOStreamManager- See Also:
XMLIOStreamManager.saveRootElement( Element )
saveRootElement
public void saveRootElement(org.jdom.Element rootEl)
throws IOException
- Description copied from class:
XMLIOStreamManager
- Write to the output Stream performing an xml to text conversion
- Overrides:
saveRootElement
in class XMLIOStreamManager
- Parameters:
rootEl
- is the root Element that gets converted
to text and dumped in the output file.
- Throws:
IOException
- from the output method of XMLOutputter- See Also:
XMLOutputter.output( Document, OutputStream )
isXMLFileZipped
public boolean isXMLFileZipped()
setXMLFileZipped
public void setXMLFileZipped(boolean isZipped)
Copyright © 2000-2007 FreeHEP. All Rights Reserved.