Code example for Node

Methods: getOwnerDocument

0
	_root = root;
	if (root instanceof Document) {
	  _document = (Document)root;
	} 
	else if (root != null) {
	  _document = root.getOwnerDocument();
	} 
	else { 
	  final DocumentBuilderFactory factory = 
		DocumentBuilderFactory.newInstance();
	  _document = factory.newDocumentBuilder().newDocument();
	  _root = _document;
	} 
	 
	_nextSibling = nextSibling;
    } 
     
    public SAX2DOM(Node root) throws ParserConfigurationException {
        this(root, null);
    }