try { if (debug) log.debug ("Sending a message ..."); transport.sendMessage (aMessage, aMessage.getAllRecipients ());
try { if (debug) log.debug ("Sending a message ... " + aMessage); transport.sendMessage (aMessage, aMessage.getAllRecipients ()); if (debug) log.debug ("Done.");
    protected void _sendMessageNow (ERMessage message, Transport transport)        throws MessagingException {        boolean debug = log.isDebugEnabled ();	MimeMessage aMessage  = message.mimeMessage ();	Object callbackObject = message.callbackObject ();	MessagingException exception = null;	// Send the message	try {	    if (debug) log.debug ("Sending a message ...");	    transport.sendMessage (aMessage, aMessage.getAllRecipients ());            stats.updateMemoryUsage ();            	    if (debug) {                String allRecipientsString = null;                try {                    allRecipientsString = message.allRecipientsAsString();                } catch (MessagingException ex) {                    allRecipientsString = "(not available)";                }                            log.debug ("(" + stats.formattedUsedMemory() + ") Message sent: " + allRecipientsString);            }	} catch (SendFailedException e) {		    if (debug)		log.debug ("Failed to send message: \n" +                           message.allRecipientsAsString() +                           e.getMessage ());	    stats.incrementErrorCount ();	    if (callbackObject != null) {		SendFailedException sfex = (SendFailedException)e;		NSArray invalidEmails = ERMailUtils.convertInternetAddressesToNSArray		    ((InternetAddress [])sfex.getInvalidAddresses ());		this.notifyInvalidEmails (callbackObject, invalidEmails);	    }	    	    exception = e;	} catch (MessagingException e) {	    exception = e;	} finally {	    stats.incrementMailCount ();	    if (exception != null)		throw exception;	}    }