aspose file tools
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes why bean is not implementing Component Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Reply Bookmark "why bean is not implementing Component" Watch "why bean is not implementing Component" New topic
Author

why bean is not implementing Component

Priteshaaa Agrawal
Greenhorn

Joined: Jun 10, 2007
Posts: 4
Hi,

Why bean is not implementing the component interface?

Thanks
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35252
    
    7
Welcome to JavaRanch.

Which interface called Component are you talking about? The only one in J2SE/JEE with that name is java.awt.Component, but that has nothing to do with EJB.
[ September 28, 2007: Message edited by: Ulf Dittmer ]

Android appsImageJ pluginsJava web charts
Priteshaaa Agrawal
Greenhorn

Joined: Jun 10, 2007
Posts: 4
Hi,

I am talking about component interface of EJB.
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 35252
    
    7
Maybe I'm a bit dense, but there is no interface called Component in EJB (as I mentioned in my previous post). Can you describe in more detail what you're asking about, or post the fully qualified class name (including the package)?
[ September 28, 2007: Message edited by: Ulf Dittmer ]
Somnath Jamdar
Greenhorn

Joined: May 28, 2004
Posts: 22
Hi Priteshaaa,

Because Component Interface is a Client View of a bean and bean resides and executes on the server in a different tier.

Container will provide the implementation for methods [getEJBLocalHome(), getPrimaryKey(), remove(), etc] defined in EJBLocalObject/EJBObject.

But the bean should provide implementation for the business method defined in the component interface.

HTH


Somnath Jamdar<br />SCJP, SCWCD
Awishek sinha
Ranch Hand

Joined: Jun 24, 2007
Posts: 62
Originally posted by Priteshaaa Agrawal:
Hi,

Why bean is not implementing the component interface?

Thanks


Hi Priteshaaa
the bean class is not required to implement the component interface (but you can do so..)as its not a marker interface(as it extends EJBObject which has methods decalred in it like remove(),getHandle() etc)so if you do so the you have to write the concrete implementation of that methods .
So at the time deployment the deployer tells the container that here is the component & home interface of this bean ,the container would implement these interface by constructing an class called EJBObject & EJBHome which the client would use to intract with the bean..
Hope it clears..


Awishek Kr Sinha<br />SCJP 1.4<br />SCBCD 1.3
 
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to run our stuff on 16 servers instead of 3.
 
subject: why bean is not implementing Component
 
Similar Threads
Not implementing Remote Interface
HFEJB mock question, Page 367
why remote interface not implemented?
EJB & Component Interface
Help me regarding basics of E.J.B