Java Annotation Processor: Difference between revisions

From NovaOrdis Knowledge Base
Jump to navigation Jump to search
Line 12: Line 12:
The Pluggable Annotation Processing API is specified by [https://jcp.org/en/jsr/detail?id=269 JSR 269] and can be used to develop custom annotation processors. Annotation processing is actively used in many Java libraries, for instance to generate metaclasses in [[JPA]] or to augment classes with boilerplate code in [[Lombok]] library.  
The Pluggable Annotation Processing API is specified by [https://jcp.org/en/jsr/detail?id=269 JSR 269] and can be used to develop custom annotation processors. Annotation processing is actively used in many Java libraries, for instance to generate metaclasses in [[JPA]] or to augment classes with boilerplate code in [[Lombok]] library.  


The processing API can only be used to generate new files, not change the existing ones. Lombok is an [[exception]].
The processing API can only be used to generate new files, not change the existing ones. Lombok is an [[Lombok#Not_a_Typical_Use|exception]].

Revision as of 06:27, 1 November 2018

External

Internal

Overview

The Pluggable Annotation Processing API is specified by JSR 269 and can be used to develop custom annotation processors. Annotation processing is actively used in many Java libraries, for instance to generate metaclasses in JPA or to augment classes with boilerplate code in Lombok library.

The processing API can only be used to generate new files, not change the existing ones. Lombok is an exception.