The OpenD Programming Language

Logger.log

This function logs data to the used Logger depending on a explicitly passed condition with the LogLevel of the used Logger.

In order for the resulting log message to be logged the LogLevel of the used Logger must be greater or equal than the global LogLevel and the condition must be true.

Parameters

condition bool

The condition must be true for the data to be logged.

args T

The data that should be logged.

Examples

auto s = new FileLogger(stdout);
s.log(true, 1337, "is number");
s.log(true, 1337, "is number");
s.log(true, 1337, "is number");
s.log(false, 1337, "is number");
s.log(false, 1337, "is number");

Meta