*
The moose likes EJB and other Java EE Technologies and the fly likes when it will get executed? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "when it will get executed?" Watch "when it will get executed?" New topic
Author

when it will get executed?

Suhas Madap
Ranch Hand

Joined: Aug 29, 2006
Posts: 52
Hi,
May I know, when the ejbCreate() method will get executed? Can we pass arguments to the ejbCreate()? If so for which session bean, we should do that? please explain this some pratical scenario.


Thank you,<br /> <br />Suhas K Madap<br /> <br />If you understand what you're doing, you're not learning anything."
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30526
    
150

Originally posted by Suhas Madap:
Hi,
May I know, when the ejbCreate() method will get executed?

ejbCreate() is called behind the scenes when the client calls create() on your EJB's home interface.

Can we pass arguments to the ejbCreate()?

Yes. You can write your own ejbCreate methods and then those signatures are valid.

If so for which session bean, we should do that? please explain this some pratical scenario.

This is more frequently done for entity beans than session beans. You could use it for stateless session beans though - if you wanted to pass some initialization information.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: when it will get executed?