gecko-dev/mailnews/compose/public/nsISmtpUrl.idl
mscott%netscape.com 1f4bc2c530 Bug #14928 --> added nsIMailtoUrl interface and reduced the functionality
of nsISmtpUrl which was acting as both mailto and smtp
r=sspitzer
1999-11-18 08:37:06 +00:00

87 lines
3.6 KiB
Plaintext

/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*-
*
* The contents of this file are subject to the Netscape Public
* License Version 1.1 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
* implied. See the License for the specific language governing
* rights and limitations under the License.
*
* The Original Code is mozilla.org code.
*
* The Initial Developer of the Original Code is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998 Netscape Communications Corporation. All
* Rights Reserved.
*
* Contributor(s):
*/
#include "nsISupports.idl"
#include "nsIFileSpec.idl"
%{ C++
#define SMTP_PORT 25
%}
interface nsIMsgIdentity;
[scriptable, uuid(16ADF2F1-BBAD-11d2-804E-006008128C4E)]
interface nsISmtpUrl : nsISupports {
///////////////////////////////////////////////////////////////////////////////
// SMTP Parse specific getters --> retrieves portions from the url spec...
///////////////////////////////////////////////////////////////////////////////
// Caller must call PR_FREE on list when it is done with it. This list is a list of all
// recipients to send the email to. each name is NULL terminated...
void GetAllRecipients(out string aRecipientsList);
attribute boolean PostMessage;
// the message can be stored in a file....allow accessors for getting and setting
// the file name to post...
attribute nsIFileSpec PostMessageFile;
///////////////////////////////////////////////////////////////////////////////
// SMTP Url instance specific getters and setters --> info the protocol needs
// to know in order to run the url...these are NOT event sinks which are things
// the caller needs to know...
///////////////////////////////////////////////////////////////////////////////
// by default the url is really a bring up the compose window mailto url...
// you need to call this function if you want to force the message to be posted
// to the mailserver...
// the user's full name and user's email address are encapsulated in the senderIdentity.
// (the user's domain name can be glopped from the user's email address)
//
// NOTE: the SMTP username and SMTP server are in the mailto url
// mailto://sspitzer@tintin/...
attribute nsIMsgIdentity senderIdentity;
};
[scriptable, uuid(5EE2AFF7-9C6F-11d3-98A3-001083010E9B)]
interface nsIMailtoUrl : nsISupports {
///////////////////////////////////////////////////////////////////////////////
// Mailto parse specific getters
///////////////////////////////////////////////////////////////////////////////
// mscott: I used to have individual getters for ALL of these fields but it was
// getting way out of hand...besides in the actual protocol, we want all of these
// fields anyway so why go through the extra step of making the protocol call
// 12 get functions...
// All of these fields are things we can effectively extract from a
// mailto url if it contains all of these values
void GetMessageContents(out string aToPart, out string aCcPart, out string aBccPart,
out string aFromPart, out string aFollowUpToPart, out string aOrganizationPart,
out string aReplyToPart, out string aSubjectPart, out string aBodyPart, out string aHtmlPart,
out string aReferencePart, out string aAttachmentPart, out string aPriorityPart,
out string aNewsgroupPart, out string aNewsHostPart, out boolean aforcePlainText);
};