Hi: Nobody knows. You won't find all the members in one exam. But you will never know which member will appear in your exam. So try to memorize them all, in a way you feel convenient, if it is possible.
Howdy all, The official Sun objectives for wrappers explicitly states the methods you need: doubleValue, floatValue, intValue, etc. and parseXxx, getXxx, toString and toHexString. But... and this is an important BUT -- there is an error in the objective, and the getXxx methods will NOT be on the exam. However, the valueOf() methods *could* be on the exam. So if it's not on the list above, and replacing the getXxx with the valueOf() methods, there are no other wrapper methods you are required to know. Tip: Be SURE you know which can throw a NumberFormatException and why. Think about anything that might have to do parsing to get a numeric value out of a String. So, the constructors that take a String can throw the exception. The parseXxx() methods obviously can throw that exception, and the valueOf() methods can throw the exception (again, because they take a String). The valueOf() method is really just another approach to creating a Wrapper object. Instead of directly calling a constructor (new Integer(...)), you call a static valueOf() method, with an option to pass in the radix. Integer i = Integer.valueOf("101011", 2); // converts 101011 to 43, then uses it to construct and Integer object which is then assigned to the variable 'i'. And I got my information from this really cool new certification book. Hope the author's don't mind. Cheers, Kathy
Strange!!! If getXxx() methods are not going to be there in the exam, why can't Sun remove it from the objectives from their site? - Manish
Joined: Aug 05, 2001
I think all the knowledge relate to each other to a certain degree. So don't be surprised if you see something you feel beyond the exam objective. Let me put it in another way: there is no way you can review the exam. So it is better to stay on the safe side.