Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What are wrapper classes?

Answer Posted / guest

The wrapper classes can take constructors of either the
type they are designed to wrap or of a String that can be
converted to that type. Thus the Integer class can take a
number that could be contained by an int, but an error will
occur if you try to pass a number with a floating point
component. Remember that the wrapper classes are just that
classes, they are not primitives and instances of the
wrappers can only be manipulated in the same way as any
class. You may get questions on the exam with code that
uses standard math operations to manipulate instances of
wrappers. You can of course use the + operator where it
would implicitly call the toString method, but as soon as
you see the - * or % operator, beware.

Is This Answer Correct ?    7 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a default constructor and also define copy contrucyor?

1046


Is java call by value?

1024


Explain the differences between static and dynamic variables?

1082


How to convert string to char and vice versa?

956


How do you represent a space in regex java?

957


What do you know about the garbate collector?

977


Is java a virus?

897


Can we access the non-final local variable, inside the local inner class?

963


how to create daemon thread in java?

1011


What is lazy initialization in java?

939


How can an object be unreferenced?

979


How can we make sure main() is the last thread to finish in java program?

1143


What is type inference in java8?

976


Describe the various concepts related to object oriented programming (oop).

974


What is the java reflection api? Why it’s so important to have?

924