Menu

SLF4j

Alcibiade

Ascii Art With SLF4j

Pre-requisites

You should include the asciiart-slf4j and its dependencies
in your project. If you use maven:

    :::xml
    <dependency>
        <groupId>org.alcibiade</groupId>
        <artifactId>asciiart-slf4j</artifactId>
        <version>0.1-SNAPSHOT</version>
    </dependency>

Sample

22:34:55.331 [main] INFO  org.alcibiade.asciiarttest.App - Here is a basic log line
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - +--------+
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - | Fruits |
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - +--------+
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - | Orange |
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - | Apple  |
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - | Lemon  |
22:34:55.348 [main] INFO  org.alcibiade.asciiarttest.App - +--------+

Source code:

    :::java
    List<String> items = new ArrayList<String>();
    items.add("Orange");
    items.add("Apple");
    items.add("Lemon");

    AsciiArtLogger logger = new AsciiArtLogger(LoggerFactory.getLogger(App.class));
    logger.info("Here is a basic log line");
    logger.info(items, "Fruits");

Related

Documentation: Home

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.