NAnt SDK Documentation - v0.92 |

# MailLogger Class

Buffers log messages from DefaultLogger, and sends an e-mail with the results.

For a list of all members of this type, see MailLogger Members.

System.Object
NAnt.Core.DefaultLogger
NAnt.Core.MailLogger

[Visual Basic]
<Serializable, _ Serializable>
Public Class MailLogger
Inherits DefaultLogger
[C#]
[Serializable]
[Serializable]
public class MailLogger : DefaultLogger

#### Thread Safety

Public static (Shared in Visual Basic) members of this type are safe for multithreaded operations. Instance members are not guaranteed to be thread-safe.

#### Remarks

The following properties are used to send the mail :

Property | Description
--- | ---
MailLogger.mailhost | Mail server to use. [default: localhost]
MailLogger.from | The address of the e-mail sender.
MailLogger.failure.notify | Send build failure e-mails ? [default: true]
MailLogger.success.notify | Send build success e-mails ? [default: true]
MailLogger.failure.to | The address to send build failure messages to.
MailLogger.success.to | The address to send build success messages to.
MailLogger.failure.subject | The subject of build failure messages. [default: "Build Failure"]
MailLogger.success.subject | The subject of build success messages. [default: "Build Success"]
MailLogger.success.attachments | The ID of a fileset holdng set of files to attach when the build is successful.
MailLogger.failure.attachments | The ID of a fileset holdng set of files to attach when the build fails.
MailLogger.body.encoding | The encoding type of the body of the e-mail message. [default: system's ANSI code page]
MailLogger.smtp.username | The name of the user to login to the SMTP server.
MailLogger.smtp.password | The password of the specified user.
MailLogger.smtp.enablessl | Specifies whether to use SSL to encrypt the connection. [default: false]
MailLogger.smtp.port | The SMTP server port to connect to. [default: 25]

#### Requirements

Namespace: NAnt.Core

Assembly: NAnt.Core (in NAnt.Core.dll)

#### See Also

MailLogger Members | NAnt.Core Namespace