com.aspose.email

Interfaces

Classes

Enums

Exceptions

com.aspose.email

Class FileAppender

  • All Implemented Interfaces:
    IAppender, com.aspose.ms.System.IDisposable


    public final class FileAppender
    extends Appender

    Reprensents a file appender.

    • Constructor Detail

      • FileAppender

        public FileAppender()

        Initializes a new instance of the FileAppender class.

      • FileAppender

        public FileAppender(String fileName)

        Initializes a new instance of the FileAppender class.

        Parameters:
        fileName - The file name.
      • FileAppender

        public FileAppender(String fileName,
                    boolean useDate)

        Initializes a new instance of the FileAppender class.

        Parameters:
        fileName - The file name.
        useDate - Indicates if date is used in file name
      • FileAppender

        public FileAppender(String fileName,
                    IFormatter formatter)

        Initializes a new instance of the FileAppender class.

        Parameters:
        fileName - The file name.
        formatter - Log formatter
      • FileAppender

        public FileAppender(String fileName,
                    boolean useDate,
                    IFormatter formatter)

        Initializes a new instance of the FileAppender class.

        Parameters:
        fileName - The file name.
        useDate - Indicates if date is used in file name
        formatter - Log formatter
    • Method Detail

      • getFileName

        public final String getFileName()

        Gets or sets file name.

      • setFileName

        public final void setFileName(String value)

        Gets or sets file name.

      • getUseDate

        public final boolean getUseDate()

        Gets or sets value which indicates whether date is used for logging.

      • setUseDate

        public final void setUseDate(boolean value)

        Gets or sets value which indicates whether date is used for logging.

      • getEncoding

        public final String getEncoding()

        Gets or sets the encoding.

      • setEncoding

        public final void setEncoding(String value)

        Gets or sets the encoding.

      • append

        public void append(LogEntry logEntry)

        Appends the log entry information to the appender.

        Specified by:
        append in interface IAppender
        Specified by:
        append in class Appender
        Parameters:
        logEntry - The log entry.
      • append

        public final void append(LogEntry[] logEntries)

        Appends a set of log entries to the appender.

        Parameters:
        logEntries - A set of log entries to log.
      • close

        public void close()

        Closes the appender.

        Overrides:
        close in class Appender