org.apache.batik.bridge.svg12

Class SVG12ScriptingEnvironment

public class SVG12ScriptingEnvironment extends ScriptingEnvironment

Manages scripting handlers for SVG 1.2 'handler' elements.
Nested Class Summary
protected classSVG12ScriptingEnvironment.DOMAttrModifiedListener
protected classSVG12ScriptingEnvironment.DOMNodeInsertedListener
The listener class for 'DOMNodeInserted' event.
protected classSVG12ScriptingEnvironment.DOMNodeRemovedListener
The listener class for 'DOMNodeRemoved' event.
protected classSVG12ScriptingEnvironment.Global
The SVGGlobal object.
protected classSVG12ScriptingEnvironment.HandlerScriptingEventListener
To handle a scripting event with an XML Events style handler.
Field Summary
protected TriplyIndexedTablehandlerScriptingListeners
The listeners for XML Events style handlers.
static StringHANDLER_SCRIPT_DESCRIPTION
Constant used to describe handler scripts.
Constructor Summary
SVG12ScriptingEnvironment(BridgeContext ctx)
Creates a new SVG12ScriptingEnvironment.
Method Summary
protected voidaddDocumentListeners()
Adds DOM listeners to the document.
protected voidaddScriptingListenersOn(Element elt)
Adds the scripting listeners to the given element.
WindowcreateWindow(Interpreter interp, String lang)
Creates a new Window object.
protected voidremoveDocumentListeners()
Removes DOM listeners from the document.
protected voidremoveScriptingListenersOn(Element elt)
Removes the scripting listeners from the given element.

Field Detail

handlerScriptingListeners

protected TriplyIndexedTable handlerScriptingListeners
The listeners for XML Events style handlers. Maps (event namespace, event local name, element) to a handler.

HANDLER_SCRIPT_DESCRIPTION

public static final String HANDLER_SCRIPT_DESCRIPTION
Constant used to describe handler scripts. {0} - URL of document containing script. {1} - Event type {2} - Event namespace {3} - line number of element.

Constructor Detail

SVG12ScriptingEnvironment

public SVG12ScriptingEnvironment(BridgeContext ctx)
Creates a new SVG12ScriptingEnvironment.

Parameters: ctx the bridge context

Method Detail

addDocumentListeners

protected void addDocumentListeners()
Adds DOM listeners to the document.

addScriptingListenersOn

protected void addScriptingListenersOn(Element elt)
Adds the scripting listeners to the given element.

createWindow

public Window createWindow(Interpreter interp, String lang)
Creates a new Window object.

removeDocumentListeners

protected void removeDocumentListeners()
Removes DOM listeners from the document.

removeScriptingListenersOn

protected void removeScriptingListenersOn(Element elt)
Removes the scripting listeners from the given element.
Copyright B) 2007 Apache Software Foundation. All Rights Reserved.