Use of the SetIsPrivateData() method generated by isPrivateData attribute should be avoided as much as possible because the value set may not reflect the status of the context in which the transferable was created.
Used for initializing the referrer when downloading a file promise.
The principal of the source dom node this transferable was created from and the contentPolicyType for the transferable. Note, currently only used on Windows for network principal and contentPolicyType information in clipboard and drag operations.
Optional
aInstancePtr: objectA run time mechanism for interface discovery.
NS_OK if the interface is supported by the associated instance, NS_NOINTERFACE if it is not.
aInstancePtr must not be null.
[in] A requested interface IID
[out] A pointer to an interface pointer to receive the result.
Initializes a transferable object. This should be called on all transferable objects. Failure to do so will result in fatal assertions in debug builds.
The load context is used to track whether the transferable is storing privacy- sensitive information.
To get the appropriate load context in Javascript callers, one needs to get to the document that the transferable corresponds to, and then get the load context from the document like this:
var loadContext = doc.defaultView.docShell .QueryInterface(Ci.nsILoadContext);
In C++ callers, if you have the corresponding document, you can just call Document::GetLoadContext to get to the load context object.
the load context associated with the transferable object. This can be set to null if a load context is not available.
Sets the data in the transferable with the specified flavor. The transferable will maintain its own copy the data, so it is not necessary to do that beforehand.
the flavor of data that is being set
the data, either some variant of class in nsISupportsPrimitives.idl, an nsIFile, or an nsIFlavorDataProvider (see above)
Generated using TypeDoc
The cookieJarSettings of the source dom node this transferable was created from.