|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.cargo.module.AbstractDescriptorIo
org.codehaus.cargo.module.application.ApplicationXmlIo
public final class ApplicationXmlIo
Provides convenience methods for reading and writing enterprise application deployment descriptors (application.xml).
Method Summary | |
---|---|
static ApplicationXml |
parseApplicationXml(java.io.InputStream input,
org.xml.sax.EntityResolver entityResolver)
Parses a deployment descriptor provided as input stream. |
static ApplicationXml |
parseApplicationXmlFromFile(java.io.File file,
org.xml.sax.EntityResolver entityResolver)
Parses a deployment descriptor stored in a regular file. |
static void |
writeApplicationXml(ApplicationXml appXml,
java.io.File file)
Writes the specified document to a file. |
static void |
writeApplicationXml(ApplicationXml appXml,
java.io.File file,
java.lang.String encoding)
Writes the specified document to a file. |
static void |
writeApplicationXml(ApplicationXml appXml,
java.io.File file,
java.lang.String encoding,
boolean isIndent)
Writes the specified document to a file. |
static void |
writeApplicationXml(ApplicationXml appXml,
java.io.OutputStream output,
java.lang.String encoding,
boolean isIndent)
Writes the specified document to an output stream. |
Methods inherited from class org.codehaus.cargo.module.AbstractDescriptorIo |
---|
createDocumentBuilder, createDocumentBuilder, getEntityResolver, parseXml, parseXml, writeAll, writeDescriptor, writeDescriptor, writeDescriptor, writeDescriptor |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static ApplicationXml parseApplicationXmlFromFile(java.io.File file, org.xml.sax.EntityResolver entityResolver) throws java.io.IOException, org.jdom.JDOMException
file
- The file to parseentityResolver
- A SAX entity resolver, or null
to use the default
java.io.IOException
- If an I/O error occurs
org.jdom.JDOMException
- If the file could not be parsedpublic static ApplicationXml parseApplicationXml(java.io.InputStream input, org.xml.sax.EntityResolver entityResolver) throws java.io.IOException, org.jdom.JDOMException
input
- The input streamentityResolver
- A SAX entity resolver, or null
to use the default
java.io.IOException
- If an I/O error occurs
org.jdom.JDOMException
- If the input could not be parsedpublic static void writeApplicationXml(ApplicationXml appXml, java.io.File file) throws java.io.IOException
appXml
- The descriptor to serializefile
- The file to write to
java.io.IOException
- If an I/O error occurspublic static void writeApplicationXml(ApplicationXml appXml, java.io.File file, java.lang.String encoding) throws java.io.IOException
appXml
- The descriptor to serializefile
- The file to write toencoding
- The character encoding to use
java.io.IOException
- If an I/O error occurspublic static void writeApplicationXml(ApplicationXml appXml, java.io.File file, java.lang.String encoding, boolean isIndent) throws java.io.IOException
appXml
- The descriptor to serializefile
- The file to write toencoding
- The character encoding to useisIndent
- Whether the written XML should be indented
java.io.IOException
- If an I/O error occurspublic static void writeApplicationXml(ApplicationXml appXml, java.io.OutputStream output, java.lang.String encoding, boolean isIndent) throws java.io.IOException
appXml
- The descriptor to serializeoutput
- The output stream to write toencoding
- The character encoding to useisIndent
- Whether the written XML should be indented
java.io.IOException
- If an I/O error occurs
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |