Struct xpcom::interfaces::nsIAddonPolicyService [] [src]

#[repr(C)]
pub struct nsIAddonPolicyService { /* fields omitted */ }

interface nsIAddonPolicyService : nsISupports

/**
 * This interface allows the security manager to query custom per-addon security
 * policy.
 */

Methods

impl nsIAddonPolicyService
[src]

[src]

Cast this nsIAddonPolicyService to one of its base interfaces.

impl nsIAddonPolicyService
[src]

[src]

/**
   * Returns the base content security policy, which is applied to all
   * extension documents, in addition to any custom policies.
   */

readonly attribute AString baseCSP;

[src]

/**
   * Returns the default content security policy which applies to extension
   * documents which do not specify any custom policies.
   */

readonly attribute AString defaultCSP;

[src]

/**
   * Returns the content security policy which applies to documents belonging
   * to the extension with the given ID. This may be either a custom policy,
   * if one was supplied, or the default policy if one was not.
   */

AString getAddonCSP (in AString aAddonId);

[src]

/**
   * Returns the generated background page as a data-URI, if any. If the addon
   * does not have an auto-generated background page, an empty string is
   * returned.
   */

ACString getGeneratedBackgroundPageUrl (in ACString aAddonId);

[src]

/**
   * Returns true if the addon was granted the |aPerm| API permission.
   */

boolean addonHasPermission (in AString aAddonId, in AString aPerm);

[src]

/**
   * Returns true if unprivileged code associated with the given addon may load
   * data from |aURI|.  If |aExplicit| is true, the <all_urls> permission and
   * permissive host globs are ignored when checking for a match.
   */

boolean addonMayLoadURI (in AString aAddonId, in nsIURI aURI, [optional] in boolean aExplicit);

[src]

/**
   * Returns the name of the WebExtension with the given ID, or the ID string
   * if no matching add-on can be found.
   */

AString getExtensionName (in AString aAddonId);

[src]

/**
   * Returns true if a given extension:// URI is web-accessible.
   */

boolean extensionURILoadableByAnyone (in nsIURI aURI);

[src]

/**
   * Maps an extension URI to the ID of the addon it belongs to.
   */

AString extensionURIToAddonId (in nsIURI aURI);

Methods from Deref<Target = nsISupports>

[src]

Cast this nsISupports to one of its base interfaces.

[src]

void QueryInterface (in nsIIDRef uuid, [iid_is (uuid), retval] out nsQIResult result);

[src]

[noscript,notxpcom] nsrefcnt AddRef ();

[src]

[noscript,notxpcom] nsrefcnt Release ();

Trait Implementations

impl XpCom for nsIAddonPolicyService
[src]

IID: nsIID = nsID(2315472633, 40212, 19549, [131, 25, 6, 193, 171, 87, 75, 170])

[src]

Perform a QueryInterface call on this object, attempting to dynamically cast it to the requested interface type. Returns Some(RefPtr) if the cast succeeded, and None otherwise. Read more

impl RefCounted for nsIAddonPolicyService
[src]

[src]

Increment the reference count.

[src]

Decrement the reference count, potentially freeing backing memory.

impl Deref for nsIAddonPolicyService
[src]

The resulting type after dereferencing.

[src]

Dereferences the value.