    

 ## On this page

  

 

 # Class ansys::dpf::core::logging::LoggerConfig

 Last update: 25.03.2026 

<a id="classansys-dpf-core-logging-loggerconfig"></a>

![](https://img.shields.io/badge/language-C%2B%2B-blue "C++")![](https://img.shields.io/badge/-public-brightgreen "public")

The configuration associated to a [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger). It allows setting the log level and the sinks of a logger.

## Members

- [defaultConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1af32d34dcb6b85561e8afec9f3d7fcccf)
- [getLogLevel](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a28a5fcb631af6a4b6fce9accc454d0b6)
- [getSinks](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a7e8c7c7932c1cae127097be0c7fd319b)
- [LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a4b15b9ab50086d77382b8a6f4e26e04a)
- [withLogLevel](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a2983b56f4fe817a94ee5be8b26cfdcf1)
- [withSinks](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a1a4aed950f872b32cea69ef415b2f7b7)
- [withSinks](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a141dbb92316f11466e18bdb9ffb1e21e)

## Public functions

<a id="classansys-dpf-core-logging-loggerconfig-1a4b15b9ab50086d77382b8a6f4e26e04a"></a>

### Function LoggerConfig

![](https://img.shields.io/badge/-public-brightgreen "public")

```cpp
ansys::dpf::core::logging::LoggerConfig::LoggerConfig()

```

Construct a new [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger) Config object.

**Return type**:

<a id="classansys-dpf-core-logging-loggerconfig-1a28a5fcb631af6a4b6fce9accc454d0b6"></a>

### Function getLogLevel

![](https://img.shields.io/badge/-public-brightgreen "public")![](https://img.shields.io/badge/-const-lightblue "const")

```cpp
eLogLevel ansys::dpf::core::logging::LoggerConfig::getLogLevel() const

```

Get the loglevel for the [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger).

**Returns**:

eLogLevel

**Return type**: eLogLevel

<a id="classansys-dpf-core-logging-loggerconfig-1a7e8c7c7932c1cae127097be0c7fd319b"></a>

### Function getSinks

![](https://img.shields.io/badge/-public-brightgreen "public")![](https://img.shields.io/badge/-const-lightblue "const")

```cpp
std::set< eLoggerSink > const  & ansys::dpf::core::logging::LoggerConfig::getSinks() const

```

Get the list of sink types supported by the [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger).

**Returns**:

std::set&lt;eLoggerSink&gt; const&amp;

**Return type**: std::set&lt; eLoggerSink &gt; const &amp;

<a id="classansys-dpf-core-logging-loggerconfig-1a2983b56f4fe817a94ee5be8b26cfdcf1"></a>

### Function withLogLevel

![](https://img.shields.io/badge/-public-brightgreen "public")

```cpp
LoggerConfig & ansys::dpf::core::logging::LoggerConfig::withLogLevel(eLogLevel log_level)

```

Sets the log level for the [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger).

**Parameters**:

- **log\_level**: The [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger) loglevel.

**Returns**:

[LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig)&amp;

**Parameters**:

- eLogLevel **log\_level**

**Return type**: [LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a4b15b9ab50086d77382b8a6f4e26e04a) &amp;

<a id="classansys-dpf-core-logging-loggerconfig-1a1a4aed950f872b32cea69ef415b2f7b7"></a>

### Function withSinks

![](https://img.shields.io/badge/-public-brightgreen "public")

```cpp
LoggerConfig & ansys::dpf::core::logging::LoggerConfig::withSinks(eLoggerSink sink)

```

Sets a single sink for the [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger) to write to.

**Parameters**:

- **sink**: The sink to write to.

**Returns**:

[LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig)&amp;

**Parameters**:

- eLoggerSink **sink**

**Return type**: [LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a4b15b9ab50086d77382b8a6f4e26e04a) &amp;

<a id="classansys-dpf-core-logging-loggerconfig-1a141dbb92316f11466e18bdb9ffb1e21e"></a>

### Function withSinks

![](https://img.shields.io/badge/-public-brightgreen "public")

```cpp
LoggerConfig & ansys::dpf::core::logging::LoggerConfig::withSinks(std::set< eLoggerSink > const &sinks)

```

Sets a list of sinks for the [Logger](classansys-dpf-core-logging-logger.md#classansys-dpf-core-logging-logger) to write to.

**Parameters**:

- **sinks**: The sinks to write to.

**Returns**:

[LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig)&amp;

**Parameters**:

- std::set&lt; eLoggerSink &gt; const &amp; **sinks**

**Return type**: [LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a4b15b9ab50086d77382b8a6f4e26e04a) &amp;

## Public static functions

<a id="classansys-dpf-core-logging-loggerconfig-1af32d34dcb6b85561e8afec9f3d7fcccf"></a>

### Function defaultConfig

![](https://img.shields.io/badge/-public-brightgreen "public")![](https://img.shields.io/badge/-static-lightgrey "static")

```cpp
static LoggerConfig ansys::dpf::core::logging::LoggerConfig::defaultConfig()

```

Returns the default config for logging.

**Returns**:

[LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig)

**Return type**: [LoggerConfig](classansys-dpf-core-logging-loggerconfig.md#classansys-dpf-core-logging-loggerconfig-1a4b15b9ab50086d77382b8a6f4e26e04a)