This week's book giveaway is in the Agile and other Processes forum.
We're giving away four copies of The Mikado Method and have Ola Ellnestam and Daniel Brolund on-line!
See this thread for details.
The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes HF: Page291 Q.3 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 "HF: Page291 Q.3" Watch "HF: Page291 Q.3" New topic
Author

HF: Page291 Q.3

Purvesh Vora
Ranch Hand

Joined: Dec 10, 2003
Posts: 47
Hi,
The Q.3 says
Which are ways in which a client can get a reference to an existing entity object's local component interface?(Choose all that apply.)

A. Call ejbCreate()
B. Call getSessionContext()
C. Obtain the reference from the handle.
D. Receive the reference as a parameter in a method call.
E. Use a finder method defined in the local home interface.

Correct answers are D and E. That are fine.
But Ans. A is wrong. And the reason is said that "we said existing"

Even if its a NEW entity then also answer A is wrong. Because the client can NEVER call ejbCreate(). She can call create() not ejbCreate()...
Is my understanding correct?


Regards,<br />Purvesh<br />SCJP, SCBCD, IBM Exam #486
Anil Chandran
Greenhorn

Joined: Apr 11, 2005
Posts: 15
I also think so :-)


I started out with nothing..I still have most of it ...
sawan parihar
Ranch Hand

Joined: Aug 24, 2004
Posts: 250
Hi,
Appreciate if someone cas explain why option C is wrong.

Sawan


Sawan<br />SCJP,SCWCD,SCBCD<br /> <br />Every exit is an entry somewhere.
Purvesh Vora
Ranch Hand

Joined: Dec 10, 2003
Posts: 47
Hi Sawan,

Option C is wrong because there are no HANDLE for the LOCAL interface. Handles are only for Remote interfaces.
sawan parihar
Ranch Hand

Joined: Aug 24, 2004
Posts: 250
oh. My mistake. I should have read the question carefully.


Yes your are right the client can call the create() method and the container will call the ejbCreate since its an callback method.

Thanks.
[ May 10, 2005: Message edited by: sawan parihar ]
 
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: HF: Page291 Q.3
 
Similar Threads
help
Ch-5 Q No.5 Coffee Cram Mock Exam
HF P288 Q3
Get a reference to an existing entity object's component interface
Coffee Cram questions 3 and 5 in entity bean intro