• 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

Is this incorrect? bad question

 
Ranch Hand
Posts: 352
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Q4)
Which of the following statement(s) are not true about JavaBeans?

* a) JavaBeans implements java.io.serializable interface.
* b) JavaBeans provides no argument constructor.
* c) JavaBeans provides getter and setter method for accessing its properties.
* d) JavaBeans class can contain public instance variable.
* e) None of the above

My answer: b,c?
Their answer: a,d
 
Ranch Hand
Posts: 759
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Of course their answer is true. JavaBeans cannot has public instance variable, they must be encapsulated. and JavaBeans doesn't implements java.io.Serializable. It is SCJP question isn't it?

Jeffry Kristianto Yanuar
SCJP 5.0
SCJA
SCJD (Working on UrlyBird 1.3.2)
 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
But here is written, that javabeans implements this interface:

http://www.stardeveloper.com/articles/display.html?article=2001071901&page=1

? I am confused, too

Sybyll
 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am confused too. There got to be some reason behind it. Either the question is not put in correctly or the answer to the question is misleading. Need some experienced input here .... Anybody???
[ August 06, 2008: Message edited by: Asif ]
 
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
http://java.sun.com/docs/books/tutorial/javabeans/whatis/index.html

Read the section describing persistence to learn more.

Enjoy!
 
Stephen Davies
Ranch Hand
Posts: 352
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
java.io.Serializable. It is SCJP question isn't it?

Actually this was from a SCJA mock exam site
 
Stephen Davies
Ranch Hand
Posts: 352
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by James Clark:
http://java.sun.com/docs/books/tutorial/javabeans/whatis/index.html

Read the section describing persistence to learn more.

Enjoy!



..Which confirms that JavaBeans implements the java.io.serializable interface,
so the set answer is worng as by selecting it they suggest that JavaBeans do not implement the serialieable interface!
 
Jimmy Clark
Ranch Hand
Posts: 2187
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
...and also confirms that any non-Sun Microsystems technical documentation or "mock exam site" may contain incorrect information.

Mock at your own risk
 
reply
    Bookmark Topic Watch Topic
  • New Topic