 | LoggerCreatorDelegate Delegate |
Defines the
LoggerCreator function used to return custom
logger implementations.
Namespace:
Neon.Diagnostics
Assembly:
Neon.Common (in Neon.Common.dll) Version: 2.10.0
Syntaxpublic delegate INeonLogger LoggerCreatorDelegate(
LogManager logManager,
string module,
TextWriter writer,
string contextId,
Func<bool> isLogEnabledFunc
)
Public Delegate Function LoggerCreatorDelegate (
logManager As LogManager,
module As String,
writer As TextWriter,
contextId As String,
isLogEnabledFunc As Func(Of Boolean)
) As INeonLogger
public delegate INeonLogger^ LoggerCreatorDelegate(
LogManager^ logManager,
String^ module,
TextWriter^ writer,
String^ contextId,
Func<bool>^ isLogEnabledFunc
)
type LoggerCreatorDelegate =
delegate of
logManager : LogManager *
module : string *
writer : TextWriter *
contextId : string *
isLogEnabledFunc : Func<bool> -> INeonLogger
Parameters
- logManager
- Type: Neon.DiagnosticsLogManager
The parent log manager. - module
- Type: SystemString
The case sensitive logger event source module (defaults to null). - writer
- Type: System.IOTextWriter
Optionally specifies a target TextWriter. This can be useful for
redirecting the ourput of a text logger to a file or somewhere else. This parameter
may be ignored for non-text based loggers or for other logger specific reasons.
- contextId
- Type: SystemString
Optionally specifies additional information that can be used to identify
context for logged events. For example, the Neon.Cadence client uses this
to record the ID of the workflow recording events.
- isLogEnabledFunc
- Type: SystemFuncBoolean
Optionally specifies a function that will be called at runtime to
determine whether to actually log an event. This defaults to null
which will always log events.
Return Value
Type:
INeonLoggerThe
INeonLogger instance.
See Also