Skip to end of metadata
Go to start of metadata

FB::JSAPIImpl Class Reference

JavaScript API base class implementation -- provides basic functionality for C++ JSAPI objects. More...

#include <JSAPIImpl.h>

Inheritance diagram for FB::JSAPIImpl:
Inheritance graph
Collaboration diagram for FB::JSAPIImpl:
Collaboration graph

List of all members.

Public Member Functions

 JSAPIImpl (void)
 Default constructor.
virtual ~JSAPIImpl (void)
 Finaliser.
void invalidate ()
 Invalidates this object.
virtual void shutdown ()
 Called to notify the object that the plugin is shutting down.
virtual void pushZone (const SecurityZone &securityLevel)
 Pushes a new security level and locks a mutex (for every Push there *must* be a Pop!).
virtual void popZone ()
 Pops off a security level and unlocks the mutex (for every Push there *must* be a Pop!).
virtual void setDefaultZone (const SecurityZone &securityLevel)
 Sets the default zone (the zone the class operates on before a push).
virtual SecurityZone getDefaultZone () const
 Gets the default zone (the zone the class operates on before a push).
virtual SecurityZone getZone () const
 Gets the currently active zone.
virtual void registerEvent (const std::string &name)
 Register event so that event listeners can be added/attached from javascript.
virtual void registerEvent (const std::wstring &name)
virtual void registerEventMethod (const std::string &name, JSObjectPtr &event)
 Called by the browser to register an event handler method.
virtual void registerEventMethod (const std::wstring &name, JSObjectPtr &event)
virtual void unregisterEventMethod (const std::string &name, JSObjectPtr &event)
 Called by the browser to unregister an event handler method.
virtual void unregisterEventMethod (const std::wstring &name, JSObjectPtr &event)
virtual void registerEventInterface (const JSObjectPtr &event)
 Called by the browser to register a JSObject interface that handles events. This is primarily used by IE. Objects provided to this method are called when events are fired by calling a method of the event name on the event interface.
virtual void unregisterEventInterface (const JSObjectPtr &event)
 Called by the browser to unregister a JSObject interface that handles events.

Protected Member Functions

virtual void FireEvent (const std::wstring &eventName, const std::vector< variant > &args)
virtual void FireEvent (const std::string &eventName, const std::vector< variant > &args)
 Fires an event into javascript asynchronously.
virtual void FireJSEvent (const std::string &eventName, const FB::VariantMap &members, const FB::VariantList &arguments)
 Fires an event into javascript asynchronously using a W3C-compliant event parameter.
virtual void FireJSEvent (const std::string &eventName, const FB::VariantMap &params)
virtual void FireJSEvent (const std::string &eventName, const FB::VariantList &arguments)

Detailed Description

JavaScript API base class implementation -- provides basic functionality for C++ JSAPI objects.

JSAPIImpl is the base class for C++ objects that interact with Javascript. It provides some basic functionality that is shared with most C++ JSAPI implementations. If you want to provide an interface to something else, such as an object from Javascript, you probably want to extend JSAPI instead so as not to get the extra (unused) functionality from this class

Author:
Richard Bateman
See also:
FB::JSAPI
FB::JSAPIAuto
Since:
1.5

Definition at line 49 of file JSAPIImpl.h.


The documentation for this class was generated from the following files:

Generated on 18 Jun 2013 for FireBreath by  doxygen 1.6.1
Labels
  • None