• 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 ...
  • Campbell Ritchie
  • Ron McLeod
  • Tim Cooke
  • Paul Clapham
  • Liutauras Vilda
  • Junilu Lacar
  • Rob Spoor
  • Jeanne Boyarsky
Saloon Keepers:
  • Stephan van Hulst
  • Carey Brown
  • Tim Holloway
  • Piet Souris

Question in ejbcertificate regarding programming restrictions

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

I came across this question at ejbcertificate and was quite blanked. What does the choice #5 mean??

Question: Identify correct programming restrictions that a Bean provider must follow to ensure that the enterprise bean is portable and can be deployed in any compliant EJB 2.0 Container. [Select 3 correct answers]
1The enterprise bean cannot define read and write to static fields.
2The enterprise bean cannot make use of the Java Swing API.
3The enterprise bean cannot make use of interfaces to define business methods.
4The enterprise bean cannot make use of the Sun JavaMail API.
5The enterprise bean must not attempt to define a class in a package.


Answers 1, 2 and 5 are correct.

Answer 1 is correct. This rule is required to ensure consistent runtime semantics because while some EJB Containers may use a single JVM to execute all enterprise bean's instances, others may distribute the instances across multiple JVMs.

Answer 2 is correct. Most servers do not allow direct interaction between an application program and a keyboard/display attached to the server system.

Answer 5 is correct. This function is reserved for the EJB Container. Allowing the enterprise bean to perform this function would create a security hole.What does this mean??!

Answer 3 is incorrect. It is possible to create an interface and implement the interface to make available in the enterprise bean business method.

Answer 4 is incorrect. The enterprise bean can make use of the JavaMail API.


Author & Gold Digger
Posts: 7617
IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Please have a look at the following discussion


There is no greater crime than stealing somebody's best friend. I miss you tiny ad:
The Low Tech Laboratory Movie Kickstarter is LIVE NOW!
    Bookmark Topic Watch Topic
  • New Topic