• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

home business methods?

 
Ranch Hand
Posts: 173
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi folks,

A home business method is defined as a method that returns something other than a component interface reference, that is, data from the entity rather than a reference to the entity itself (page 278 HFEJB).

On page 325 we are told there are three ways to get EJBObject references: 1. a finder method on the home,
2. a create method on the home,
3. a home business method "that returns a reference to the beans component interface."

Surely this last case is a finder method, not a home business method? Or am I missing something? Please understand that I am not trying to split hairs or make a pedentic or trivial point. I got a question wrong in a Mock exam because I misunderstood this issue.

When the book talks about receiving an EJBObject reference as a parameter in a method call, am I right in thinking that this method uses a finder method to get the reference and then simply returns it, or is there more to it?

best regards
Simon
 
Ranch Hand
Posts: 3178
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Simon Ingram:

Surely this last case is a finder method, not a home business method? Or am I missing something?

When the book talks about receiving an EJBObject reference as a parameter in a method call, am I right in thinking that this method uses a finder method to get the reference and then simply returns it, or is there more to it?


The last case is not a finder method. Finder method is at option-1. The last case is just a home business method that returns a reference to the bean's component interface. A home business method can return anything, which is compliant to RMI-IIOP...

On page 278, the book just explains that home business mthods can return something other than EJB Object references... it doesn't mean that it cannot return EJB Object reference... So rather than using finder methods and create methods to get a reference to an EJB Object, we can use home business method to get one...
 
Simon Ingram
Ranch Hand
Posts: 173
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks, Ko Ko. I figured this was the case, but there is nothing like confirmation!

regards
Simon
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic