|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK 11g Release 2 (11.1.2.0.0) E17493-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.ide.extension.ElementVisitor javax.ide.extension.ExtensionHook javax.ide.extension.DeferredElementVisitorHook
public class DeferredElementVisitorHook
DeferredElementVisitorHook is a specialized hook handler class that helps clients with existing custom hook handlers convert to a lazier, pull based model. If DeferredElementVisitorHook is registered as the hook handler for an element, it will record the XML data for all instances of that element encountered during extension.xml processing. At a later time, when that data is needed, the client would retrieve the DeferredElementVisitorHook instance from the ExtensionRegistry and call attachElementVisitor() passing an ElementVisitor implementation. Before attachElementVisitor() returns, all of the recorded XML data will be replayed to the attached ElementVisitor instance visitor methods (start/end). DeferredElementVisitor attempts to replicate the original parsing context (such as scope data and locators), such that the attached ElementVisitor would have access to the same information it would have if it had been registered as the hook handler. Once an ElementVisitor is attached, if additional instances of the element are encountered during extension.xml processing, they will be directly passed to the attached ElementVisitor's start/end method with no buffering.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.ide.extension.ExtensionHook |
---|
ExtensionHook.URIResource |
Nested classes/interfaces inherited from class javax.ide.extension.ElementVisitor |
---|
ElementVisitor.ResourceBundleProvider |
Field Summary |
---|
Fields inherited from class javax.ide.extension.ExtensionHook |
---|
KEY_EXTENSION, KEY_RSBUNDLE_CLASS, MANIFEST_XMLNS |
Fields inherited from class javax.ide.extension.ElementVisitor |
---|
KEY_LOCATOR |
Constructor Summary | |
---|---|
DeferredElementVisitorHook()
|
Method Summary | |
---|---|
void |
attachElementVisitor(ElementVisitor elementVisitor)
When the XML data associated with the hook handler instance needs to be processed, call this method passing an ElementVisitor implementation. |
void |
end(ElementEndContext context)
Visit the end tag of an xml element. |
ElementVisitor |
getAttachedElementVisitor()
Returns the attached ElementVisitor. |
boolean |
isElementVisitorAttached()
Returns true if an ElementVisitor is attached |
void |
start(ElementStartContext context)
Visit the start tag of an xml element. |
Methods inherited from class javax.ide.extension.ExtensionHook |
---|
findPath, getExtension, getProvider, getRSBundleClass, getSchemaLocation, resolvePath, setProvider, setSchemaLocation |
Methods inherited from class javax.ide.extension.ElementVisitor |
---|
getAttributeHelper, getClassLoader, getMetaClassLoader, getResourceBundle, getResourceBundleProvider, getTextHelper, log, log, setResourceBundleProvider |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DeferredElementVisitorHook()
Method Detail |
---|
public void start(ElementStartContext context)
ElementVisitor
This implementation does nothing.
start
in class ElementVisitor
context
- information about the xml start tag.public void end(ElementEndContext context)
ElementVisitor
This implementation does nothing.
end
in class ElementVisitor
context
- information about the xml end tag.public void attachElementVisitor(ElementVisitor elementVisitor)
elementVisitor
- public boolean isElementVisitorAttached()
attachElementVisitor(ElementVisitor)
public ElementVisitor getAttachedElementVisitor()
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK 11g Release 2 (11.1.2.0.0) E17493-01 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |