APIBackend
#
- class ansys.mechanical.core.embedding.logger.windows_api.APIBackend#
Provides API backend for Mechanical logging system.
Overview#
Flush the log manually. |
|
Enable logging. |
|
Disable logging. |
|
Set the log level for Mechanical based on the Python log level. |
|
Set whether to auto flush to the standard log file. |
|
Set the location to write the log file to. |
|
Set the base location to write the log file to. |
|
Return whether a message with the given severity is outputted to the log. |
|
Log the message to the configured logging mechanism. |
Import detail#
from ansys.mechanical.core.embedding.logger.windows_api import APIBackend
Method detail#
- APIBackend.set_log_level(level: int, sink: int = sinks.StandardSinks.CONSOLE) None #
Set the log level for Mechanical based on the Python log level.
- APIBackend.set_base_directory(base_directory: str) None #
Set the base location to write the log file to.
The base directory contains time-stamped subfolders where the log file is actually written to. If a base directory is set, it takes precedence over the
set_directory
location.This does not have an API to set at runtime.