Back to index

lightning-sunbird  0.9+nobinonly
Public Member Functions | Private Attributes
nsMsgDeliveryListener Class Reference

#include <nsMsgDeliveryListener.h>

Inheritance diagram for nsMsgDeliveryListener:
Inheritance graph
Collaboration diagram for nsMsgDeliveryListener:
Collaboration graph

List of all members.

Public Member Functions

 nsMsgDeliveryListener (nsMsgDeliveryCompletionCallback callback, nsMsgDeliveryType delivType, nsISupports *tagData)
virtual ~nsMsgDeliveryListener ()
NS_IMETHOD OnStopRunningUrl (nsIURI *aUrl, nsresult aExitCode)
NS_IMETHOD SetMsgComposeAndSendObject (nsIMsgSend *obj)
NS_IMETHOD SetMsgSendLaterObject (nsMsgSendLater *obj)
void OnStartRunningUrl (in nsIURI url)
void OnStopRunningUrl (in nsIURI url, in nsresult aExitCode)

Private Attributes

nsCOMPtr< nsISupports > mTagData
nsMsgDeliveryType mDeliveryType
nsCOMPtr< nsIMsgSendmMsgSendObj
nsMsgDeliveryCompletionCallback mCompletionCallback

Detailed Description

Definition at line 65 of file nsMsgDeliveryListener.h.

Constructor & Destructor Documentation

Definition at line 103 of file nsMsgDeliveryListener.cpp.

#if defined(DEBUG_ducarroz)
  printf("CREATE nsMsgDeliveryListener: %x\n", this);

  mTempFileSpec = nsnull;
  mDeliveryType = delivType;
  mTagData = tagData;
  mCompletionCallback = callback;
  mMsgSendObj = nsnull;
  mMsgSendLaterObj = nsnull;

Definition at line 118 of file nsMsgDeliveryListener.cpp.

#if defined(DEBUG_ducarroz)
  printf("DISPOSE nsMsgDeliveryListener: %x\n", this);

  delete mTempFileSpec;

Member Function Documentation

Here is the caller graph for this function:

Definition at line 46 of file nsMsgDeliveryListener.cpp.

#ifdef NS_DEBUG
//  printf("Starting to run the delivery operation\n");

  if (mMsgSendObj)
    mMsgSendObj->NotifyListenerOnStartSending(nsnull, nsnull);

  if (mMsgSendLaterObj)
       return NS_OK;
void nsIUrlListener::OnStopRunningUrl ( in nsIURI  url,
in nsresult  aExitCode 
) [inherited]

Here is the caller graph for this function:

Definition at line 62 of file nsMsgDeliveryListener.cpp.

  nsresult rv = NS_ERROR_UNEXPECTED;
#ifdef NS_DEBUG
//  printf("\nOnStopRunningUrl() called!\n");

  // First, stop being a listener since we are done.
  if (aUrl)
              // query it for a mailnews interface for now....
              nsCOMPtr<nsIMsgMailNewsUrl> mailUrl = do_QueryInterface(aUrl);
              if (mailUrl)

  if (mMsgSendObj)
                                  nsnull,     // const char *aMsgID, 
                                  aExitCode,  // nsresult aStatus, 
                                  nsnull,     // const PRUnichar *aMsg, 
                                  nsnull);    // nsIFileSpec *returnFileSpec);

  if (mMsgSendLaterObj)
                            nsnull,  // const PRUnichar *aMsg, 
                            nsnull,  // PRUint32 aTotalTried, 
                            nsnull); // PRUint32 aSuccessful);

  // Now, important, if there was a callback registered, call the 
  // creators exit routine.
  if (mCompletionCallback)
    rv = (*mCompletionCallback) (aUrl, aExitCode, mDeliveryType, mTagData);
    rv = NS_OK;

       return rv;

Here is the call graph for this function:

Definition at line 128 of file nsMsgDeliveryListener.cpp.

  mMsgSendObj = obj;
  return NS_OK;

Definition at line 135 of file nsMsgDeliveryListener.cpp.

  mMsgSendLaterObj = obj;
  return NS_OK;

Member Data Documentation

Definition at line 88 of file nsMsgDeliveryListener.h.

Definition at line 85 of file nsMsgDeliveryListener.h.

Definition at line 87 of file nsMsgDeliveryListener.h.

Definition at line 86 of file nsMsgDeliveryListener.h.

nsCOMPtr<nsISupports> nsMsgDeliveryListener::mTagData [private]

Definition at line 83 of file nsMsgDeliveryListener.h.

Definition at line 84 of file nsMsgDeliveryListener.h.

The documentation for this class was generated from the following files: