org.jdom.contrib.input.scanner
Interface ElementListener


public interface ElementListener

The interface objects listening for element creation notification fired by ElementScanner shall implement.

Author:
Laurent Bihanic

Method Summary
 void elementMatched(java.lang.String path, org.jdom.Element e)
          Notifies of the parsing of an Element.
 

Method Detail

elementMatched

void elementMatched(java.lang.String path,
                    org.jdom.Element e)
                    throws org.jdom.JDOMException
Notifies of the parsing of an Element.

ElementScanner invokes this method when encountering the closing tag of the element definition. Thus, element e and all its child nodes are fully built but the parent element is not.

Note that the element is not attached to any document and that the parent element is null unless another listener is listening on one of the element ancestors.

As no copy of the notified elements is performed, all changes made on element e will be visible of the not-yet-notified listeners listening on this same element and of the listeners listening on one of the element ancestors.

Parameters:
path - the path to the parsed element.
e - the parsed Element.
Throws:
org.jdom.JDOMException - if the listener wishes to abort the parsing of the input XML document.


Copyright © 2011 Jason Hunter, Brett McLaughlin. All Rights Reserved.