DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Mercurial (e8606a6a0c25)

VCS Links

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */


#include "nsISupports.idl"

interface nsIPluginTag;
interface nsIVariant;

[scriptable, uuid(a6dcc76e-9f62-4cc1-a470-b483a1a6f096)]
interface nsIBlocklistService : nsISupports
{
  // Indicates that the item does not appear in the blocklist.
  const unsigned long STATE_NOT_BLOCKED = 0;
  // Indicates that the item is in the blocklist but the problem is not severe
  // enough to warant forcibly blocking.
  const unsigned long STATE_SOFTBLOCKED = 1;
  // Indicates that the item should be blocked and never used.
  const unsigned long STATE_BLOCKED     = 2;
  // Indicates that the item is considered outdated, and there is a known
  // update available.
  const unsigned long STATE_OUTDATED    = 3;
  // Indicates that the item is vulnerable and there is an update.
  const unsigned long STATE_VULNERABLE_UPDATE_AVAILABLE = 4;
  // Indicates that the item is vulnerable and there is no update.
  const unsigned long STATE_VULNERABLE_NO_UPDATE = 5;

  // Unused; Please increment if we add more blocklist states.
  const unsigned long STATE_MAX = 6;

  /**
   * Determine the blocklist state of a plugin
   * @param   plugin
   *          The plugin to get the state for
   * @param   appVersion
   *          The version of the application we are checking in the blocklist.
   *          If this parameter is null, the version of the running application
   *          is used.
   * @param   toolkitVersion
   *          The version of the toolkit we are checking in the blocklist.
   *          If this parameter is null, the version of the running toolkit
   *          is used.
   * @returns Promise that resolves to the STATE constant.
   */
  Promise getPluginBlocklistState(in nsIPluginTag plugin,
                                  [optional] in AString appVersion,
                                  [optional] in AString toolkitVersion);

  readonly attribute boolean isLoaded;
};