annotation
2 posts
Groovy 3 @NullCheck annotation - less code and less NPE
Groovy 3 helps you write less, but more secure code. Today I want to show you one of the features added in the latest release - @NullCheck
annotation.
How to remove any class annotation with Groovy compiler configuration script?
One of the most interesting Groovy features is its ability to configure advanced compiler[1] options using DSL script. It becomes handy when you want to apply some global modifications to all Groovy classes. (For instance, you want to add @CompileStatic
annotation to all classes, without applying changes to the source code). In most cases, you want to add something to the existing source code, e.g., classes imports or useful annotations, but what if we want to remove one annotation or another?