File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Programmer Certification (SCJP/OCPJP) and the fly likes Wrapper class Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Certification » Programmer Certification (SCJP/OCPJP)
Bookmark "Wrapper class " Watch "Wrapper class " New topic

Wrapper class

Sun Craven

Joined: Mar 13, 2008
Posts: 27
why the following statement is incorrect?
Every wrapper has a public void toString(); method
Sun Craven
Jart Bo
Ranch Hand

Joined: Oct 22, 2007
Posts: 144
Hi Sun,

Actually there is a method

public String toString()

for the wrapper classes. The return type void is wrong.
[ April 15, 2008: Message edited by: Jart Bo ]

Sun Craven

Joined: Mar 13, 2008
Posts: 27

Yeah .I C.Thank you Jart.
I am careless..
I agree. Here's the link:
subject: Wrapper class
It's not a secret anymore!