Hierarchy GetLogger Method (String) | Apache log4net™ SDK Documentation

Return a new logger instance named as the first parameter using the default factory.

Namespace: log4net.Repository.Hierarchy
Assembly: log4net (in log4net.dll) Version: 2.0.8.0-.NET 4.0
Syntax

C#
VB
C++
F#
Copy

    public override ILogger GetLogger(
    	string name
    )

    Public Overrides Function GetLogger (
    	name As String
    ) As ILogger

    public:
    virtual ILogger^ GetLogger(
    	String^ name
    ) override

    abstract GetLogger :
            name : string -> ILogger
    override GetLogger :
            name : string -> ILogger

#### Parameters

name
  Type: System
  String
  The name of the logger to retrieve

#### Return Value

Type: ILogger
The logger object with the name specified

#### Implements

ILoggerRepository
GetLogger(String)
Remarks

Return a new logger instance named as the first parameter using the default factory.

If a logger of that name already exists, then it will be returned. Otherwise, a new logger will be instantiated and then linked with its existing ancestors as well as children.

See Also

#### Reference

Hierarchy Class
GetLogger Overload
log4net.Repository.Hierarchy Namespace