Questions tagged [postconstruct]

@PostConstruct is a Java EE annotation used to select a method that needs to be executed after dependency injection is done to perform any initialization.

The @PostConstruct annotation is used on a method that needs to be executed after dependency injection is done to perform any initialization. This method MUST be invoked before the class is put into service.

This annotation is recognized by all Java EE compliant containers as well as .

See also

242 questions
-1
votes
1 answer

How to set a list for addEntry with PostConstruct

Until now I add the things I want to have in my list over the getter which makes no sense and end in a mess up in my database, when adding a new entry. My model until now: @Data @Entity public class Telefonbuch { /*@PostConstruct public void…
CptDayDreamer
  • 1,526
  • 6
  • 25
  • 61
-1
votes
1 answer

I'm getting warning from PostConstruct annotated init method

I'm getting this warning from @PostConstruct annotated init method Nis 18, 2014 2:46:10 PM com.sun.faces.vendor.WebContainerInjectionProvider getAnnotatedMethodForMethodArr WARNING: JSF1047: Method 'public void…
Burak
  • 13
  • 1
  • 3
  • 11
1 2 3
16
17