|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.generationjava.io.xml.XmlWriter
public class XmlWriter
Makes writing XML much much easier.
Constructor Summary | |
---|---|
XmlWriter(java.io.Writer writer)
Create an XmlWriter on top of an existing java.io.Writer. |
Method Summary | |
---|---|
void |
close()
Close this writer. |
XmlWriter |
endEntity()
End the current entity. |
static void |
main(java.lang.String[] args)
Replace a string with another string inside a larger string, for the first n values of the search string. |
static void |
test1()
|
static void |
test2()
|
XmlWriter |
writeAttribute(java.lang.String attr,
java.lang.String value)
Write an attribute out for the current entity. |
XmlWriter |
writeEntity(java.lang.String name)
Begin to output an entity. |
XmlWriter |
writeText(java.lang.String text)
Output body text. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public XmlWriter(java.io.Writer writer)
Method Detail |
---|
public XmlWriter writeEntity(java.lang.String name) throws WritingException
String
- name of entity.
WritingException
public XmlWriter writeAttribute(java.lang.String attr, java.lang.String value) throws WritingException
String
- name of attribute.String
- value of attribute.
WritingException
public XmlWriter endEntity() throws WritingException
WritingException
public void close() throws WritingException
WritingException
public XmlWriter writeText(java.lang.String text) throws WritingException
WritingException
public static void main(java.lang.String[] args) throws WritingException
text
- String to do search and replace inrepl
- String to search forwith
- String to replace withn
- int values to replace
WritingException
public static void test1() throws WritingException
WritingException
public static void test2() throws WritingException
WritingException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |