Creates jsaction dispatcher that serves as registry for action handlers and dispatches actions to appropriate handlers.
Instance Method Summary | |
attach(?goog.jsaction.EventContract contract) Attaches this dispatcher to the given EventContract instance. | |
dispatch(string action, !Element elem, !Event e, number time) ⇒ boolean Dispatches an action to the appropriate handler function. | |
hasQueuedActionInNamespace_(string ns) ⇒ boolean Determines whether there is a queued action for the given namespace. | |
maybeInvokeHandler_(string action, !Element elem, !Event e, number time) ⇒ boolean Looks up the handler for an action an invokes it (if present). | |
registerHandlers(string ns, !Object handlers) Registers action handlers. | |
registerLoader(string ns, !goog.jsaction.LoaderFunction loaderFn) Registers a loader function for a namespace. The loader function will be invoked when an action occurs from that namespace without a handler being present. The loader is expected to do whatever necessary to load code and eventually register action handlers for the namespace. | |
replayEvents_() Replays all events in the queue for which there is a handler. |
Static Method Summary | |
assertValidAction_(string action) Asserts the validity of fully qualified action name. | |
getNamespace_(string action) ⇒ string Extracts and returns the namespace from a fully qualified jsaction of the form "namespace.actionname". |