|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.threed.jpct.util.XMLFactory
XMLFactory is a small factory to parse XML-files. XMLFactory and XMLNode
provide a simple and fast possibility to parse XML-files without the overhead
of other, much bigger XML-libraries. The possibilities of this approach may
be limited but at least it's fast, small and easy to use.
The XML won't be validated against its DTD or schema.
Method Summary | |
void |
filter(XMLNode xmlRoot,
XMLNode xmlFilter)
Removes nodes from the tree whose path don't match the filter-node's path. |
static XMLFactory |
getInstance()
Returns the instance of the XMLFactory. |
java.util.Vector |
getMatchingNodes(java.lang.String pattern,
XMLNode node)
Gets the nodes that match the pattern in "mynode/mynode2/mynode3"-form starting from the given node. |
XMLNode |
parseXML(java.lang.String xml)
Parses the xml. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static XMLFactory getInstance()
public XMLNode parseXML(java.lang.String xml)
xml
- the xml to parse
public void filter(XMLNode xmlRoot, XMLNode xmlFilter)
xmlRoot
- the root of the XML-treexmlFilter
- the filter to applypublic java.util.Vector getMatchingNodes(java.lang.String pattern, XMLNode node)
pattern
- the patternnode
- the starting node
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |