镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

SimpleLogger example

Philip John Roman edited this page May 17, 2020 · 2 revisions

Example on how to use SLF4J with this project

Documentation

Please take a look at the offical documentation of SLF4J.

Example

Add the simple logger to your project

Maven:

<dependency>
  <groupId>org.slf4j</groupId>
  <artifactId>slf4j-simple</artifactId>
  <version>1.7.25</version>
</dependency>

Gradle:

implementation group: 'org.slf4j', name: 'slf4j-simple', version: '1.7.25'

Use the example configuration

You can find the example configuration here.

To debug the network communication, you need to set the LogLevel to TRACE.

Include the configuration file in your jar

Done :)

Clone this wiki locally