Table of Contents

Interface ILogApiV1

Namespace
WhalesSecret.TradeScriptLib.API
Assembly
WhalesSecret.TradeScriptLib.dll

Trade script logging API interface version 1.0.0.

public interface ILogApiV1 : IVersionedApiV1
Inherited Members
Extension Methods

Fields

DefaultLayout

Default value for layout parameter in GetLogger(LogLevel, string?, string?) when the logger is created without ID.

DefaultLayoutWithId

Default value for layout parameter in GetLogger(LogLevel, string?, string?) when the logger is created with ID.

LayoutCallsite

Placeholder in the layout formatting string for callsite.

LayoutId

Placeholder in the layout formatting string for the logger ID.

LayoutInstanceId

Placeholder in the layout formatting string for current instance ID.

LayoutLevel

Placeholder in the layout formatting string for logging level.

LayoutMdlc

Placeholder in the layout formatting string for current MDLC ID.

LayoutMessage

Placeholder in the layout formatting string for the message to log.

LayoutThreadId

Placeholder in the layout formatting string for current thread ID.

LayoutTime

Placeholder in the layout formatting string for UTC date time in format yyyy-MM-dd HH:mm:ss.ffff.

Properties

IsDebugMode

true when the trade script runs in the debug mode, false if it runs in the production mode.

Methods

DeleteAllLogs(bool)

Delete all trade script logs.

Flush()

Flush any pending log messages to the log file.

GetInstanceId()

Gets the identifier of the current execution instance. The instance identifier is used to separate objects created by different executions of the trade script, such as events and logs.

GetLogger(LogLevel, string?, string?)

Creates a new logger with an optional identifier.