aspose file tools*
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Wrapper classes Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Wrapper classes" Watch "Wrapper classes" New topic
Author

Wrapper classes

Sudipta Das
Greenhorn

Joined: Apr 05, 2001
Posts: 18
All the wrapper classes (Integer, Boolean, Float, Short, Long, Double and Character)

1.are public
2.are serializable
3.are immutatable
4.extend java.lang.Number
5.are final
Art Metzer
Ranch Hand

Joined: Oct 31, 2000
Posts: 241
Sudipta Das
Greenhorn

Joined: Apr 05, 2001
Posts: 18
Originally posted by Sudipta Das:
All the wrapper classes (Integer, Boolean, Float, Short, Long, Double and Character)

1.are public
2.are serializable
3.are immutatable
4.extend java.lang.Number
5.are final


I suppose my question was misinterpreted. I meant to ask which is the correct answer of the fol. question :
All the wrapper classes (Integer, Boolean, Float, Short, Long, Double and Character)

1.are public
2.are serializable
3.are immutatable
4.extend java.lang.Number
5.are final
Thomas Paul
mister krabs
Ranch Hand

Joined: May 05, 2000
Posts: 13974
public final class Character extends Object implements java.io.Serializable
public final class Boolean implements java.io.Serializable
public final class Double extends Number
public final class Float extends Number
public final class Integer extends Number
public final class Long extends Number
public final class Short extends Number
public abstract class Number implements java.io.Serializable
So the answer is:
1, 2, 3, 5

------------------
Moderator of the Programmer Certification Forums


Associate Instructor - Hofstra University
Amazon Top 750 reviewer - Blog - Unresolved References - Book Review Blog
Thomas Paul
mister krabs
Ranch Hand

Joined: May 05, 2000
Posts: 13974
I never noticed but the Character class specifically extends Object. That's a little odd, isn't it?
 
wood burning stoves
 
subject: Wrapper classes
 
Similar Threads
toString()........
Wrapper Classes
primary key type can't be primitive type. True?
String immutability
== Vs .equals()