The moose likes EJB Certification (SCBCD/OCPJBCD) and the fly likes brain power Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » EJB Certification (SCBCD/OCPJBCD)
Bookmark "brain power" Watch "brain power" New topic

brain power

manish ahuja
Ranch Hand

Joined: Oct 23, 2003
Posts: 312
Hey All

Sorry if this question sounds a bit dumb to all the java(EJB) experts around.
This is the regarding the 1st brain power in HeadFirst EJB. (where it is mentioned it is more of Java knowledge rather than EJB knowledge)

i.e. How do we force the compiler to check whether the methods in the bean class do implement the method in the component interface even though our bean class does not implement the component interface.

Can anybody take a stab at this. If possible do illustrate with an sample case

Dale Seng
Ranch Hand

Joined: Mar 22, 2004
Posts: 275
You needn't worry about answering that one right away... the answer is given later in the book. The technique would be to create an interface, and have both implement it. This would put the compiler back in the position to make certain that both implementations had the same signatures.
manish ahuja
Ranch Hand

Joined: Oct 23, 2003
Posts: 312

Sorry for this. Where are the answers to brain power in the book. I could not find it as yet
Eusebio Floriano
Ranch Hand

Joined: Mar 07, 2004
Posts: 237
It�s on page 86.

SCJP 1.4 / 5.0 - SCBCD 1.3 - SCWCD 1.4 - IBM 484
I agree. Here's the link:
subject: brain power
jQuery in Action, 3rd edition