Announcement Announcement Module
Collapse
No announcement yet.
Autowiring class that extends JpaDaoSupport Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • Autowiring class that extends JpaDaoSupport

    I've annotated a class that extends JpaDaoSupport with the @Repository annotation.

    How do I get that class to autowire in things like its JPATemplate or EntityManager ?

    In the old days I would just get the bean to autowire by name or type.

    Effectively I need to add an autowire on the setEntityManager method on the class my class extends. I can't override this method, annotate it with an autowire, and call the superclass as setEntityManager is final.

    Is there any easy way of making a whole bean autowired via annotations ?
Working...
X