interface LogDetails {
    feature?: string;
    type?: string | object | Function;
    identity?: string | string[];
    data?: object;
    message: string;
    category?: LoggingCategory;
}

Hierarchy (view full)

Properties

feature?: string

A name for the general feature that uses it: ValueHost, Validator, Condition, Formatter, etc.

type?: string | object | Function

The object that is the source of the log message. Logging will convert it into source.constructor.name, if available. Alternatively a string as the type of source.

identity?: string | string[]

A way to identify the source of this message, such as the ValueHostName or error Code. If there are several sources, create an array. For example, when reporting a validator's error code, it helps to have the ValueHost too: ['ValueHost', 'ErrorCode']

data?: object

Additional data that the logger can use to take further actions. Only add this if LogOptions.includeData is true and you have data to share. It should be assigned to an object with name/value pairs. Those entries should be published and be consistent throughout the system as other systems are likely to use it.

message: string
category?: LoggingCategory

Helps understand the reason for the log message, such as 'Exception', 'Result', 'Configuration', 'TypeMismatch', etc.

Generated using TypeDoc v0.25.12