sbPIDataRemote2 Interface Reference

An additional interface for accessing dataremote values. Adds the ability to access values via methods rather than attributes. This is needed by the Remote API, which cannot access attributes on JavaScript XPCOM components due to Mozilla Bug 304048. In order to work around this problem we've replaced the old DataRemote class with a C++ wrapper that delegates to the old implementation using this interface. More...

import"sbPIDataRemote2.idl";

Inheritance diagram for sbPIDataRemote2:
[legend]
Collaboration diagram for sbPIDataRemote2:
[legend]

Public Member Functions

void setAsString (in AString aValue)
 
AString getAsString ()
 
void setAsInt (in long long aValue)
 
long long getAsInt ()
 
void setAsBool (in boolean aValue)
 
boolean getAsBool ()
 
- Public Member Functions inherited from sbIDataRemote
void init (in AString aKey, [optional] in AString aRoot)
 Initialize the DataRemote Sets internal state, MUST be called before any other methods. All other calls will throw exceptions if init has not been called. More...
 
void unbind ()
 Disconnect the DataRemote If this DataRemote has been bound via a call to bindObserver(), bindAttribute() or bindProperty() it must be disconnected to prevent calls back to objects that may no longer be around. More...
 
void bindObserver (in nsIObserver aObserver, [optional] in boolean aSuppressFirst)
 When the key associated with the sbDataRemote changes the observer will get a callback to observe() with the new value for the data, a handle to the sbDataRemote and the key to which the data belongs. More...
 
void bindRemoteObserver (in sbIRemoteObserver aObserver, [optional] in boolean aSuppressFirst)
 When the key associated with the sbDataRemote changes the observer will get a callback to observe() with the new value for the data, and the key to which the data belongs. More...
 
void bindProperty (in nsIDOMElement aElement, in AString aProperty, [optional] in boolean aIsBool, [optional] in boolean aIsNot, [optional] in AString aEvalString)
 When the key associated with the sbDataRemote changes the property of the element will be modified appropriately. More...
 
void bindAttribute (in nsIDOMElement aElement, in AString aProperty, [optional] in boolean aIsBool, [optional] in boolean aIsNot, [optional] in AString aEvalString)
 When the key associated with the sbDataRemote changes the attribute of the element will be modified appropriately. More...
 
void deleteBranch ()
 Called to remove the data remote and all its children. More...
 

Additional Inherited Members

- Public Attributes inherited from sbIDataRemote
attribute AString stringValue
 Access to the data in string format In javascript you can access the data as you would properties of a normal js object ( obj.stringValue = "foo" assigns the string foo into the DataRemote ). In c++ you need to call setStringValue("foo") and likewise for the getter. More...
 
attribute boolean boolValue
 Access to the data in boolean format In javascript you can access the data as you would properties of a normal js object ( obj.boolValue = true assigns the boolean true into the DataRemote ). In c++ you need to call setStringValue(true) and likewise for the getter. More...
 
attribute long long intValue
 Access to the data in integer format In javascript you can access the data as you would properties of a normal js object ( obj.intValue = 10 assigns the integer 10 into the DataRemote ). In c++ you need to call setStringValue(10) and likewise for the getter. More...
 

Detailed Description

An additional interface for accessing dataremote values. Adds the ability to access values via methods rather than attributes. This is needed by the Remote API, which cannot access attributes on JavaScript XPCOM components due to Mozilla Bug 304048. In order to work around this problem we've replaced the old DataRemote class with a C++ wrapper that delegates to the old implementation using this interface.

This entire system should be scrapped, per bug 8703.

See Also
https://bugzilla.mozilla.org/show_bug.cgi?id=304048 http://bugzilla.songbirdnest.com/show_bug.cgi?id=10806

Definition at line 47 of file sbPIDataRemote2.idl.

Member Function Documentation

boolean sbPIDataRemote2::getAsBool ( )
long long sbPIDataRemote2::getAsInt ( )
AString sbPIDataRemote2::getAsString ( )
void sbPIDataRemote2::setAsBool ( in boolean  aValue)
void sbPIDataRemote2::setAsInt ( in long long  aValue)
void sbPIDataRemote2::setAsString ( in AString  aValue)

The documentation for this interface was generated from the following file: