author R Kent James <>
Sat, 22 Aug 2015 13:40:00 -0700
changeset 18664 969a3a5cb50fff98fb5225da45e61d95e13d6671
permissions -rw-r--r--
Bug 1240327, improve ability of key mailnews components to support JsAccount, r=jcranmer

/* 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 */

#include "nsISupports.idl"
interface nsIFile;

// This interface provides minimal XPCONNECT access to objects of type
// nsMsgAttachmentHandler. This is primarily for use with new account
// types and JsAccount, so this is probably not the interface that you
// want if you are working with standard account types.

[scriptable, uuid(1731283c-60fe-4102-a804-622a84cc1a08)]
interface nsIMsgAttachmentHandler : nsISupports
  /// The real type, once we know it.
  readonly attribute ACString type;

  /// URI with link to the attachment.
  readonly attribute ACString uri;

  /// The temp file to which we save it.
  readonly attribute nsIFile tmpFile;

  /// The name for the headers, if different from the URL.
  readonly attribute AUTF8String name;

  /// Size of the attachment, in bytes.
  readonly attribute unsigned long size;

  /// This is for multipart/related Content-ID's.
  readonly attribute ACString contentId;

  /// True if this should be sent as a link to a file.
  readonly attribute boolean sendViaCloud;

  /// Name of the character set for the attachment.
  readonly attribute ACString charset;

  /// The encoding, once we've decided.
  readonly attribute ACString encoding;

  /// Whether the attachment has been encoded, for example to base64.
  readonly attribute boolean alreadyEncoded;