com.partnersoft.io.formats.xml
Class EZXMLWriter

java.lang.Object
  extended by com.partnersoft.io.formats.xml.EZXMLWriter
Direct Known Subclasses:
EZHTMLWriter

public class EZXMLWriter
extends java.lang.Object

For those times when you just want to pump out some XML, but don't want to track your indentation or do character replacement.

Author:
Paul Reavis Copyright 2003 Partner Software, Inc.

Constructor Summary
EZXMLWriter(java.io.File outputFile)
           
EZXMLWriter(java.io.Writer writer)
           
EZXMLWriter(java.io.Writer writer, boolean printDoctype)
           
 
Method Summary
 void close()
           
 void closeTag()
           
 void closeTag(boolean newLine)
           
 void closeTag(java.lang.String checkTagName)
           
 void closeTag(java.lang.String checkTagName, boolean newLine)
           
 void endComplexTag()
           
 void openTag(java.lang.String tagName)
           
 void openTag(java.lang.String tagName, boolean newLine)
           
 void startComplexTag(java.lang.String tagName)
           
 void writeContent(java.lang.Object content)
           
 void writeContent(java.lang.Object content, boolean newLine)
           
 void writeIterableContent(java.lang.String tagName, java.lang.Object content)
           
 void writeProperty(java.lang.String name, java.lang.String value)
           
 void writeRaw(java.lang.String text)
          This writes text directly to the file, without escaping XML characters.
 void writeTagAndContent(java.lang.String tag, double content)
           
 void writeTagAndContent(java.lang.String tag, int content)
           
 void writeTagAndContent(java.lang.String tag, java.lang.Object content)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EZXMLWriter

public EZXMLWriter(java.io.File outputFile)
            throws java.io.IOException
Throws:
java.io.IOException

EZXMLWriter

public EZXMLWriter(java.io.Writer writer)
            throws java.io.IOException
Throws:
java.io.IOException

EZXMLWriter

public EZXMLWriter(java.io.Writer writer,
                   boolean printDoctype)
            throws java.io.IOException
Throws:
java.io.IOException
Method Detail

openTag

public void openTag(java.lang.String tagName)
             throws java.io.IOException
Throws:
java.io.IOException

openTag

public void openTag(java.lang.String tagName,
                    boolean newLine)
             throws java.io.IOException
Throws:
java.io.IOException

closeTag

public void closeTag()
              throws java.io.IOException
Throws:
java.io.IOException

closeTag

public void closeTag(boolean newLine)
              throws java.io.IOException
Throws:
java.io.IOException

closeTag

public void closeTag(java.lang.String checkTagName)
              throws java.io.IOException
Throws:
java.io.IOException

closeTag

public void closeTag(java.lang.String checkTagName,
                     boolean newLine)
              throws java.io.IOException
Throws:
java.io.IOException

startComplexTag

public void startComplexTag(java.lang.String tagName)
                     throws java.io.IOException
Throws:
java.io.IOException

writeProperty

public void writeProperty(java.lang.String name,
                          java.lang.String value)
                   throws java.io.IOException
Throws:
java.io.IOException

endComplexTag

public void endComplexTag()
                   throws java.io.IOException
Throws:
java.io.IOException

writeTagAndContent

public void writeTagAndContent(java.lang.String tag,
                               java.lang.Object content)
                        throws java.io.IOException
Throws:
java.io.IOException

writeTagAndContent

public void writeTagAndContent(java.lang.String tag,
                               double content)
                        throws java.io.IOException
Throws:
java.io.IOException

writeTagAndContent

public void writeTagAndContent(java.lang.String tag,
                               int content)
                        throws java.io.IOException
Throws:
java.io.IOException

writeContent

public void writeContent(java.lang.Object content)
                  throws java.io.IOException
Throws:
java.io.IOException

writeContent

public void writeContent(java.lang.Object content,
                         boolean newLine)
                  throws java.io.IOException
Throws:
java.io.IOException

writeIterableContent

public void writeIterableContent(java.lang.String tagName,
                                 java.lang.Object content)
                          throws java.io.IOException
Throws:
java.io.IOException

close

public void close()
           throws java.io.IOException
Throws:
java.io.IOException

writeRaw

public void writeRaw(java.lang.String text)
              throws java.io.IOException
This writes text directly to the file, without escaping XML characters. Use if you just want to dump already-formatted XML.

Throws:
java.io.IOException