public class XMLBuffer extends Object
Constructor | Description |
---|---|
XMLBuffer() |
Modifier and Type | Method | Description |
---|---|---|
XMLBuffer |
closeTag(String tagname) |
Close top tag from stack.
|
XMLBuffer |
openTag(String tagname) |
Open a tag; save on stack.
|
XMLBuffer |
tag(String tagname,
String content) |
Add a complete tag with content.
|
XMLBuffer |
tag(String tagname,
StringBuilder content) |
Add a complete tag with content.
|
String |
toString() |
Convert the buffer to a string, closing any open tags
|
public XMLBuffer openTag(String tagname)
tagname
- name of the tagpublic XMLBuffer closeTag(String tagname)
tagname
- name of the tag to closeIllegalArgumentException
- if the tag names do not matchpublic XMLBuffer tag(String tagname, String content)
tagname
- name of the tagcontent
- content to put in tag, or empty content, if an empty tag should be usedpublic XMLBuffer tag(String tagname, StringBuilder content)
tagname
- name of the tagcontent
- content to put in tag, or empty content, if an empty tag should be usedCopyright © 1998-2018 Apache Software Foundation. All Rights Reserved.