org.jmol.util
Class XmlUtil
java.lang.Object
org.jmol.util.XmlUtil
public class XmlUtil
- extends Object
Method Summary |
static void |
appendAttrib(StringBuffer sb,
Object name,
Object value)
|
static void |
appendCdata(StringBuffer sb,
String name,
Object[] attributes,
String data)
"
will convert ]]> to ]] > |
static void |
appendTag(StringBuffer sb,
String name,
Object data)
standard data"
standard " |
static void |
appendTag(StringBuffer sb,
String name,
Object[] attributes,
Object data)
standard data" |
static void |
appendTag(StringBuffer sb,
String name,
Object[] attributes,
Object data,
boolean isCdata,
boolean doClose)
|
static void |
closeTag(StringBuffer sb,
String name)
|
static Object |
escape(String name,
List atts,
Object value,
boolean asString,
String indent)
|
static void |
openDocument(StringBuffer data)
|
static void |
openTag(StringBuffer sb,
String name)
|
static void |
openTag(StringBuffer sb,
String name,
Object[] attributes)
|
static void |
toXml(StringBuffer sb,
String name,
List properties)
|
static String |
unwrapCdata(String s)
|
static String |
wrapCdata(Object data)
wrap the string as character data, with replacements for [ noted
as a list starting with * after the CDATA termination |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
XmlUtil
public XmlUtil()
openDocument
public static void openDocument(StringBuffer data)
openTag
public static void openTag(StringBuffer sb,
String name)
openTag
public static void openTag(StringBuffer sb,
String name,
Object[] attributes)
closeTag
public static void closeTag(StringBuffer sb,
String name)
appendTag
public static void appendTag(StringBuffer sb,
String name,
Object[] attributes,
Object data,
boolean isCdata,
boolean doClose)
wrapCdata
public static String wrapCdata(Object data)
- wrap the string as character data, with replacements for [ noted
as a list starting with * after the CDATA termination
- Parameters:
data
-
- Returns:
- wrapped text
unwrapCdata
public static String unwrapCdata(String s)
- Parameters:
s
-
- Returns:
- unwrapped text
appendTag
public static void appendTag(StringBuffer sb,
String name,
Object[] attributes,
Object data)
- standard data"
- Parameters:
sb
- name
- attributes
- data
-
appendTag
public static void appendTag(StringBuffer sb,
String name,
Object data)
- standard data"
standard "
- Parameters:
sb
- name
- data
-
appendCdata
public static void appendCdata(StringBuffer sb,
String name,
Object[] attributes,
String data)
- "
will convert ]]> to ]] >
- Parameters:
sb
- name
- attributes
- data
-
appendAttrib
public static void appendAttrib(StringBuffer sb,
Object name,
Object value)
- Parameters:
sb
- name
- value
-
toXml
public static void toXml(StringBuffer sb,
String name,
List properties)
escape
public static Object escape(String name,
List atts,
Object value,
boolean asString,
String indent)