Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Invoking new() on a bean class?

 
Senthil Kumar
Ranch Hand
Posts: 264
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it possible to instantiate a bean class inside an another bean.If the container allows us to do that, do we still get those services provided by the container.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You mean without calling create ? If that's what you mean, how would you instanciate an entity bean as it is abstract ?
 
Senthil Kumar
Ranch Hand
Posts: 264
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok how about session beans.
 
Christophe Verré
Sheriff
Posts: 14691
16
Eclipse IDE Ubuntu VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you'd instanciate one, it would just be like a simple java class. It's not maintained by the container any more. So no lifecycle event, no management...
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic