WriteIf

WriteIf (1 of 5)

Writes the specified message to appenders if condition is true.

Returns: void Aspose::Email::Tools::Logging::

WriteIf(bool condition, System::SharedPtr < System::Object > message)
ParameterDescription
conditionThe condition to test.
messageThe message to write.

WriteIf (2 of 5)

Writes the specified message and exception to appenders if condition is true.

Returns: void Aspose::Email::Tools::Logging::

WriteIf(bool condition, System::SharedPtr < System::Object > message, System::Exception exception)
ParameterDescription
conditionThe condition to test.
messageThe message to write.
exceptionThe exception to write.

WriteIf (3 of 5)

Writes the specified message to appenders if condition is true.

Returns: void Aspose::Email::Tools::Logging::

WriteIf(bool condition, System::String message)
ParameterDescription
conditionThe condition to test.
messageThe message to write.

WriteIf (4 of 5)

Writes the specified message if the log level is enabled.

Returns: void Aspose::Email::Tools::Logging::

WriteIf(System::SharedPtr < LogLevel > condition, System::String message)
ParameterDescription
conditionThe log level.
messageThe message to log.

WriteIf (5 of 5)

Writes the specified message and exception if the log level is enabled.

Returns: void Aspose::Email::Tools::Logging::

WriteIf(System::SharedPtr < LogLevel > condition, System::String message, System::Exception exception)
ParameterDescription
conditionThe log level.
messageThe message to log.
exceptionThe exception to log.