• 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
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JPilot,, Java ranch exam question ID: 1

 
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Which of the following statements about business methods in a bean class is incorrect.

A.The signature requirements for business methods are always the same for both session and entity beans.

B.The argument and return types must always be legal types for the Java RMI API.

C.The throws clause may include any exceptions defined by your application.

D.A business method should always throw the javax.ejb.EJBException to indicate a system-level problem.

Correct answer was B.

why the statement at B is incorrect?
And I think the statement at C is incorrect, so C should be correct answer. Since the throws statement can not include "any exceptions defined by your application", just the ones that are not runtime exception and which do not extend java.rmi.RemoteException.

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

The throws clause may include any exceptions defined by your application



This means the exceptions defined by your application {application exceptions} which can be defined in the throws clause.

The argument and return types must always be legal types for the Java RMI API



NOT for local client view.


sawan
 
Miki Muzsi
Ranch Hand
Posts: 120
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
ok. I agree. Tricky question

Thanks.
Miki
 
reply
    Bookmark Topic Watch Topic
  • New Topic