January 2015
Beginner to intermediate
364 pages
7h 41m
English
A CDI stereotype allows us to create new annotations that bundle up several CDI annotations. For example, if we need to create several CDI named beans with a scope of session, we would have to use two annotations in each of these beans, namely @Named and @SessionScoped. Instead of having to add two annotations to each of our beans, we could create a stereotype and annotate our beans with it.
To create a CDI stereotype in NetBeans, we simply need to create a new file by selecting the Contexts and Dependency Injection category and the Stereotype file type.

Then, we need to enter a name and package for our new stereotype.
At this point, NetBeans ...
Read now
Unlock full access