mailnews/imap/public/nsIAutoSyncMsgStrategy.idl
author Mozilla Releng Treescript <release+treescript@mozilla.org>
Thu, 17 Jun 2021 08:40:28 +0000
changeset 42621 0fa58870b14d6521c1c562e10ef70d1d7f7d2c06
parent 37130 3b281b9a0b409202fd555893700881cfc1e65ce4
permissions -rw-r--r--
no bug - Bumping Thunderbird l10n changesets r=release a=l10n-bump DONTBUILD ast -> 90f850248aab9bda6eb64281ecdcf9bf58b87b0e de -> f5c3242734eb62e3351f92566b5f2449d2485e89 nb-NO -> ff6f0f3ea0706db9c07544b3b9fd627402dd8906 nn-NO -> 10ed49f6689bf511aceb33f6deb844fb751a924b sr -> 138baebc171fee68ebdd5f464487a33613772900 tr -> 093e37f5a375eda70181fa64c089869a7b7bba3f

/* 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 nsIMsgFolder;
interface nsIMsgDBHdr;

typedef long nsAutoSyncStrategyDecisionType;

[scriptable,uuid(0365bec5-3753-43c2-b13e-441747815f37)]
interface nsAutoSyncStrategyDecisions : nsISupports
{
  /// same priority
  const nsAutoSyncStrategyDecisionType Same         = 0x00000001;
  /// higher priority
  const nsAutoSyncStrategyDecisionType Higher       = 0x00000002;
  /// lower priority
  const nsAutoSyncStrategyDecisionType Lower        = 0x00000004;
};

[scriptable, uuid(9cb4baff-3112-4cf8-8463-f81b0aa78f93)]
interface nsIAutoSyncMsgStrategy : nsISupports {

  /**
   * Returns a relative-priority for the second message by comparing with the first message.
   */
  nsAutoSyncStrategyDecisionType sort(in nsIMsgFolder aFolder, in nsIMsgDBHdr aMsgHdr1, in nsIMsgDBHdr aMsgHdr2);

  /**
   * Tests whether the given message should be excluded or not.
   */
  boolean isExcluded(in nsIMsgFolder aFolder, in nsIMsgDBHdr aMsgHdr);
};