This week's book giveaway is in the HTML Pages with CSS and JavaScript forum.
We're giving away four copies of Testing JavaScript Applications and have Lucas da Costa on-line!
See this thread for details.
Win a copy of Testing JavaScript Applications this week in the HTML Pages with CSS and JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Bear Bibeault
  • Ron McLeod
  • Jeanne Boyarsky
  • Paul Clapham
  • Tim Cooke
  • Liutauras Vilda
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • fred rosenberger
  • salvin francis
  • Piet Souris
  • Frits Walraven
  • Carey Brown

Ch-5 Q No.5 Coffee Cram Mock Exam

Ranch Hand
Posts: 44
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Which are ways in which a client can get a reference to an existing entity object's remote component interface?
A. Call ejbCreate()
B. Obtain the reference from the handle.
c. Call a method on the entity object's primary key.
D. Recieve the reference as a parameter in a method call.
E. Use a finder method defined in the remote home interface.

I think i'vent understood option D well. How can the client even recieve a reference as a parameter, it can only get it as a return value. My point is that a bean would never call method on a client, so how could the reference be received as a parameter.

Same is with Q No 3.

Posts: 3036
Mac IntelliJ IDE Python VI Editor Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
No, you're right. The bean would never call a method in the client. However, something else might. That is, another client gets a reference to the bean, than calls a method on your client that passes that reference as a parameter. I'm not sure why you'd want to do that, but that didn't stop my former coworkers from doing it continously.
Ranch Hand
Posts: 372
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Parameter actually means return type here. What they mean is you can call a method on a bean, that method can look up and return the component interface reference of another bean which you can receive as the return value of that call
expectation is the root of all heartache - shakespeare. tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop
    Bookmark Topic Watch Topic
  • New Topic