jInfer

cz.cuni.mff.ksi.jinfer.xsdimportdom
Class DOMHandler

java.lang.Object
  extended by cz.cuni.mff.ksi.jinfer.xsdimportdom.DOMHandler

public class DOMHandler
extends Object

Class responsible for building rule-trees from DOM tree.

Extracts information from existing DOM tree to create rule-trees. Rule-trees are tree data structures, where vertices are instances of Element and edges are the relations between them stored in Regexp instances within vertices. Every vertex is a rule by itself, so in order to obtain IG rules, one must extract all Elements from a rule-tree.

Please read package info.


Constructor Summary
DOMHandler()
          Construct this parser, set loglevel as defined in XSD Import properties.
 
Method Summary
 List<Element> createRuleTrees(Element root)
          Create rule-trees from direct children of the root node of DOM tree.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DOMHandler

public DOMHandler()
Construct this parser, set loglevel as defined in XSD Import properties.

Method Detail

createRuleTrees

public List<Element> createRuleTrees(Element root)
                              throws XSDException,
                                     InterruptedException
Create rule-trees from direct children of the root node of DOM tree.

Returns list of Elements containing complete rule-trees of the top level tags. This method recursively builds rule-trees for all its sub-nodes, thus should be invoked only once, on the schema tag node itself.

Parameters:
root - Root of the DOM tree, (schema tag) node.
Returns:
Rule-trees of all top level element tags, or empty list if schema was empty.
Throws:
XSDException
InterruptedException

jInfer

Generated on Fri Dec 9 00:01:25 CET 2011