• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Who implements a handle?

 
Severin Stoeckli
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

From an online test:

Given this conde:

try {
Advice a = aHome.create();
Handle aHandle = a.getHandle();
} catch (Exception ex) {...}

which is true? (everything works and compiles correctly)


I marked the following answer as true:

The object referenced by aHandle is from a class implemented by the container.


The solution said false. What is your opinion?


The spec says:

7.11.6 Handle classes
The deployment tools are responsible for implementing the handle classes for the session bean�s remote home and remote interfac

Severin
 
alzamabar
Ranch Hand
Posts: 379
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, the question is tricky...I wouldn't know...
 
Lionel Orellana
Ranch Hand
Posts: 87
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
what are the other options?
 
Severin Stoeckli
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
the options are:

A) aHandle must be Serializable
B) Advice must extend EJBHome
C) The object referenced by aHandle is from a class implemented by the container
D) The Bean Provider implemented the aHome.create() method
E) getHandle declares a RemoteException
F) Hanlde extends java.rmi.Remote
G) The object referenced by 'a' IS-A java.rmi.Remote

The solution was:
A,E,G
My opinion is:
A,C,E,G

Severin
 
Valentin Crettaz
Gold Digger
Sheriff
Posts: 7610
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
C is definitely true. You can file a bug
 
Severin Stoeckli
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks! I'll

Severin
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic