wood burning stoves 2.0*
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes Invoking new()  on a bean class? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "Invoking new()  on a bean class?" Watch "Invoking new()  on a bean class?" New topic
Author

Invoking new() on a bean class?

Senthil Kumar
Ranch Hand

Joined: Mar 13, 2006
Posts: 264
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.


when you really want something, all the universe always conspires in your favour.<br /> <br />SCJP1.5-77%<br />SCWCD-89%
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

You mean without calling create ? If that's what you mean, how would you instanciate an entity bean as it is abstract ?


[My Blog]
All roads lead to JavaRanch
Senthil Kumar
Ranch Hand

Joined: Mar 13, 2006
Posts: 264
ok how about session beans.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

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...
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Invoking new() on a bean class?
 
Similar Threads
Coffe Cream on EB: mistakes/doubts #1
Session Bean cannot be final?
multithreading
Doubt On Session Bean
<jsp:UseBean> can also CREATE a bean! Or can it?