Lombok: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
(Created page with "=Overview= Lombok is a Java annotation library that helps reduce boilerplate code.")
 
No edit summary
Line 2: Line 2:


Lombok is a Java annotation library that helps reduce boilerplate code.
Lombok is a Java annotation library that helps reduce boilerplate code.
=Annotations=
==@Slf4j==
The annotation generates a SLF4J Logger in the class. It has the same effect as if you were to explicitly add the following lines within the class:
private static final org.slf4j.Logger log = org.slf4j.LoggerFactory.getLogger(MyClass.class);

Revision as of 19:50, 8 October 2018

Overview

Lombok is a Java annotation library that helps reduce boilerplate code.

Annotations

@Slf4j

The annotation generates a SLF4J Logger in the class. It has the same effect as if you were to explicitly add the following lines within the class:

private static final org.slf4j.Logger log = org.slf4j.LoggerFactory.getLogger(MyClass.class);