nsISupports
Last changed in Gecko 2.0 (Firefox 4 / Thunderbird 3.3 / SeaMonkey 2.1)Method overview
nsISupports getHelperForLanguage(in PRUint32 language); |
void getInterfaces(out PRUint32 count, [array, size_is(count), retval] out nsIIDPtr array); |
Attributes
Attribute | Type | Description |
classDescription |
string |
A human readable string naming the class, or null . Read only. |
classID |
nsCIDPtr |
A classID through which an instance of this class can be created, or null . If the flags attribute has the SINGLETON bit set, then the value of this attribute specifies a ClassID through which this class can be accessed as a service using nsIServiceManager.getService() . Read only. |
classIDNoAlloc |
nsCID |
A classID through which an instance of this class can be created, or This attribute is similar to the Exceptions thrown
|
contractID |
string |
A contractID through which an instance of this class can be created, or null . If the flags attribute has the SINGLETON bit set, then the value of this attribute specifies a ContractID through which this class may be accessed as a service using nsIServiceManager.getServiceByContractID() . Read only. |
flags |
PRUint32 |
Specifies various binary properties of this class. Possible values for this attribute include a bit-wise combination of the constants Read only. |
implementationLanguage Obsolete since Gecko 40 |
PRUint32 |
The language type in which this class is implemented. See nsIProgrammingLanguage.Constants for a list of possible values. Read only. |
Constants
Bitflags for 'flags
' attribute.
Constant | Value | Description |
SINGLETON |
1 << 0 |
The class is a singleton that must be accessed via nsIServiceManager . |
THREADSAFE |
1 << 1 |
The class may be accessed by any thread. |
MAIN_THREAD_ONLY |
1 << 2 |
The class may only be accessed by the main application thread. |
DOM_OBJECT |
1 << 3 |
The class is a DOM object. |
PLUGIN_OBJECT |
1 << 4 |
The class is a plugin object. |
CONTENT_NODE |
1 << 6 |
Specifies that this class implements Note: This flag is private and is for use by the Mozilla codebase only. |
RESERVED |
1 << 31 |
The high order bit is RESERVED for consumers of these flags. No implementor of this interface should ever return flags with this bit set. |
EAGER_CLASSINFO |
1 << 5 |
This flag is designed for use with nsGenericFactory and can be set in nsModuleComponentInfo::mFlags . It has no meaning when returned from the flags attribute of a nsIClassInfo implementation. Obsolete since Gecko 2.0 |
Methods
getHelperForLanguage()
Get a language mapping specific helper object that may assist in using objects of this class in a specific lanaguage.
For example, if asked for the helper for nsIProgrammingLanguage
::JAVASCRIPT this might return an object that can be nsISupports.QueryInterface()
'd into the nsIXPCScriptable
interface to assist XPConnect in supplying JavaScript specific behavior to callers of the instance object.
nsISupports getHelperForLanguage( in PRUint32 language );
Parameters
language
- This parameter selects the language mapping specific helper object to be returned.
nsIProgrammingLanguage
defines language identifiers that may be passed for this parameter.
Return value
Should return null
if no helper available for given language.
getInterfaces()
This method returns an ordered list of interfaces IIDs that instances of the class promise to implement.
Note that nsISupports
is an implicit member of the implemented set of interfaces and need not be included.
If this method is not supported by an implementation, then it should return 0 for count
and null
for array
.
void getInterfaces( out PRUint32 count, [array, size_is(count), retval] out nsIIDPtr array );
Parameters
count
- The length of the resulting array.
array
- The resulting array of
nsIIDPtr
values.
Remarks
This interface was finalized (frozen) for Gecko 0.9.6. See bug 99158 for details. From Gecko 2.0 interfaces are no longer frozen.