What is Lombok
and how could I use it in a java class?
What are the advantages and disadvantages of its handling in a java application?
What is Lombok
and how could I use it in a java class?
What are the advantages and disadvantages of its handling in a java application?
Lombok
is a Framework
created under license MIT
, and can be used freely in any Java project. Its main objective is to decrease the verbosity of the JPA, DTOs e Beans
mapping classes, for example.
Its advantage is to avoid repeating "cliché" code, such as creating gets and sets for all attributes, equals e hashCode, toString, Construtores
methods, and so on. That way, the code gets cleaner and clearer.
One drawback I felt was the need to install Plugin no Intellij e Eclipse
. I believe these are the IDEs
currently supported only.
I recommend using it.
Sources: