|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object zk.xml.Utl
public class Utl
Utilities for parsing XML and others.
Refer to zUtl
for basic utilities.
Method Summary | |
---|---|
static String |
getElementValue(DOMElement el)
Returns the concatenation of the text nodes under the specified DOM element. |
static DOMElement |
loadXML(String url,
Function callback)
Loads XML from the resource at the specified URL. |
static DOMElement |
parseXML(String text)
Parses and returns the XML document from the specified text. |
static String |
renType(String url,
String type)
Renames the type embedded in an URL For example,
zk.xml.Utl.renType("/zkdemo/img/whatever-off.gif", "on");
//return "/zkdemo/img/whatever-on.gif"
as shown above, it assumes the type is embedded after dash (-). |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static DOMElement loadXML(String url, Function callback)
url
- callback
-
public static DOMElement parseXML(String text)
text
-
public static String renType(String url, String type)
zk.xml.Utl.renType("/zkdemo/img/whatever-off.gif", "on");
//return "/zkdemo/img/whatever-on.gif"
as shown above, it assumes the type is embedded after dash (-).
url
- the URL to modifytype
- the type to replace with
public static String getElementValue(DOMElement el)
el
- the DOM element.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |