LogManager Exists Method (Assembly, String) | Apache log4net™ SDK Documentation

Returns the named logger if it exists.

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

C#
VB
C++
F#
Copy

    public static ILog Exists(
    	Assembly repositoryAssembly,
    	string name
    )

    Public Shared Function Exists (
    	repositoryAssembly As Assembly,
    	name As String
    ) As ILog

    public:
    static ILog^ Exists(
    	Assembly^ repositoryAssembly,
    	String^ name
    )

    static member Exists :
            repositoryAssembly : Assembly *
            name : string -> ILog

#### Parameters

repositoryAssembly
  Type: System.Reflection
  Assembly
  The assembly to use to lookup the repository.
name
  Type: System
  String
  The fully qualified logger name to look for.

#### Return Value

Type: ILog
The logger, or null if the logger doesn't exist in the specified assembly's repository.
Remarks

If the named logger exists (in the repository for the specified assembly) then it returns a reference to the logger, otherwise it returns null.

See Also

#### Reference

LogManager Class
Exists Overload
log4net Namespace