Condividi tramite


ResourceLoggerService.GetLogger Method

Definition

Overloads

GetLogger(IResource)

Gets the logger for the resource to write to.

GetLogger(String)

Gets the logger for the resource to write to.

GetLogger(IResource)

Source:
ResourceLoggerService.cs
Source:
ResourceLoggerService.cs

Gets the logger for the resource to write to.

public Microsoft.Extensions.Logging.ILogger GetLogger (Aspire.Hosting.ApplicationModel.IResource resource);
member this.GetLogger : Aspire.Hosting.ApplicationModel.IResource -> Microsoft.Extensions.Logging.ILogger
Public Function GetLogger (resource As IResource) As ILogger

Parameters

resource
IResource

The resource name

Returns

An ILogger which represents the resource.

Applies to

GetLogger(String)

Source:
ResourceLoggerService.cs
Source:
ResourceLoggerService.cs

Gets the logger for the resource to write to.

public Microsoft.Extensions.Logging.ILogger GetLogger (string resourceName);
member this.GetLogger : string -> Microsoft.Extensions.Logging.ILogger
Public Function GetLogger (resourceName As String) As ILogger

Parameters

resourceName
String

The name of the resource from the Aspire application model.

Returns

An ILogger which represents the named resource.

Applies to