Back to index

lightning-sunbird  0.9+nobinonly
nsISmtpUrl.idl
Go to the documentation of this file.
00001 /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
00002 /* ***** BEGIN LICENSE BLOCK *****
00003  * Version: MPL 1.1/GPL 2.0/LGPL 2.1
00004  *
00005  * The contents of this file are subject to the Mozilla Public License Version
00006  * 1.1 (the "License"); you may not use this file except in compliance with
00007  * the License. You may obtain a copy of the License at
00008  * http://www.mozilla.org/MPL/
00009  *
00010  * Software distributed under the License is distributed on an "AS IS" basis,
00011  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
00012  * for the specific language governing rights and limitations under the
00013  * License.
00014  *
00015  * The Original Code is mozilla.org code.
00016  *
00017  * The Initial Developer of the Original Code is
00018  * Netscape Communications Corporation.
00019  * Portions created by the Initial Developer are Copyright (C) 1998
00020  * the Initial Developer. All Rights Reserved.
00021  *
00022  * Contributor(s):
00023  *
00024  * Alternatively, the contents of this file may be used under the terms of
00025  * either of the GNU General Public License Version 2 or later (the "GPL"),
00026  * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
00027  * in which case the provisions of the GPL or the LGPL are applicable instead
00028  * of those above. If you wish to allow use of your version of this file only
00029  * under the terms of either the GPL or the LGPL, and not to allow others to
00030  * use your version of this file under the terms of the MPL, indicate your
00031  * decision by deleting the provisions above and replace them with the notice
00032  * and other provisions required by the GPL or the LGPL. If you do not delete
00033  * the provisions above, a recipient may use your version of this file under
00034  * the terms of any one of the MPL, the GPL or the LGPL.
00035  *
00036  * ***** END LICENSE BLOCK ***** */
00037 
00038 #include "nsISupports.idl"
00039 #include "nsIMsgComposeParams.idl"
00040 
00041 interface nsIMsgIdentity;
00042 interface nsIPrompt;
00043 interface nsIAuthPrompt;
00044 interface nsISmtpServer;
00045 interface nsIInterfaceRequestor;
00046 interface nsIFileSpec;
00047 
00048 [scriptable, uuid(16ADF2F1-BBAD-11d2-804E-006008128C4E)]
00049 interface nsISmtpUrl : nsISupports {
00051        // SMTP Parse specific getters --> retrieves portions from the url spec...
00053        
00054        // This list is a list of all
00055        // recipients to send the email to. each name is NULL terminated...
00056        attribute string recipients;
00057 
00058        attribute boolean PostMessage;
00059 
00060        // the message can be stored in a file....allow accessors for getting and setting
00061        // the file name to post...
00062        attribute nsIFileSpec PostMessageFile;
00063 
00065        // SMTP Url instance specific getters and setters --> info the protocol needs
00066        // to know in order to run the url...these are NOT event sinks which are things
00067        // the caller needs to know...
00069 
00070        // by default the url is really a bring up the compose window mailto url...
00071        // you need to call this function if you want to force the message to be posted
00072        // to the mailserver...
00073 
00074        // the user's full name and user's email address are encapsulated in the senderIdentity.
00075        // (the user's domain name can be glopped from the user's email address)
00076         //
00077        // NOTE:  the SMTP username and SMTP server are in the smtp url
00078        // smtp://sspitzer@tintin/...
00079        attribute nsIMsgIdentity senderIdentity;
00080     attribute nsIPrompt prompt;
00081     attribute nsIAuthPrompt authPrompt;
00082     attribute nsIInterfaceRequestor notificationCallbacks;
00083     attribute nsISmtpServer smtpServer;
00084     
00085     const PRInt32 DEFAULT_SMTP_PORT = 25;
00086     const PRInt32 DEFAULT_SMTPS_PORT = 465;
00087 };
00088 
00089 [scriptable, uuid(5EE2AFF7-9C6F-11d3-98A3-001083010E9B)]
00090 interface nsIMailtoUrl : nsISupports {
00092        // Mailto parse specific getters
00094 
00095        // mscott: I used to have individual getters for ALL of these fields but it was
00096        // getting way out of hand...besides in the actual protocol, we want all of these
00097        // fields anyway so why go through the extra step of making the protocol call
00098        // 12 get functions...
00099 
00100        // All of these fields are things we can effectively extract from a
00101        // mailto url if it contains all of these values
00102        void GetMessageContents(out string aToPart, out string aCcPart, out string aBccPart, 
00103               out string aFromPart, out string aFollowUpToPart, out string aOrganizationPart, 
00104               out string aReplyToPart, out string aSubjectPart, out string aBodyPart, out string aHtmlPart, 
00105               out string aReferencePart, out string aAttachmentPart, out string aPriorityPart, 
00106               out string aNewsgroupPart, out string aNewsHostPart, out MSG_ComposeFormat aFormat);
00107 
00108 };