Table of Contents

Class SimpleDateFormatter

Namespace
log4net.DateFormatter
Assembly
log4net.dll

Formats the DateTime using the method.

public class SimpleDateFormatter : IDateFormatter
Inheritance
SimpleDateFormatter
Implements
Inherited Members

Remarks

Formats the DateTime using the DateTime method.

Constructors

SimpleDateFormatter(string)

Constructor

public SimpleDateFormatter(string format)

Parameters

format string

The format string.

Remarks

Initializes a new instance of the SimpleDateFormatter class with the specified format string.

The format string must be compatible with the options that can be supplied to .

Methods

FormatDate(DateTime, TextWriter)

Formats the date using .

public virtual void FormatDate(DateTime dateToFormat, TextWriter writer)

Parameters

dateToFormat DateTime

The date to convert to a string.

writer TextWriter

The writer to write to.

Remarks

Uses the date format string supplied to the constructor to call the method to format the date.