Results 1 to 3 of 3

Thread: what is Autoboxing in java

  1. #1
    Junior Member
    Join Date
    May 2007
    Answers
    1

    what is Autoboxing in java

    can u tell


  2. #2
    Contributing Member
    Join Date
    May 2007
    Answers
    32

    Re: what is Autoboxing in java

    AutoBoxing means Conversion of Primitive to Wrapper Object automatically.
    this concept is newly added in java5.0.


  3. #3
    Junior Member
    Join Date
    May 2007
    Answers
    10

    Re: what is Autoboxing in java

    Quote Originally Posted by pavang View Post
    can u tell
    As any java programmer knows that we cann't put a primitive values(int,floatetc.) into collection.Collection can hold only object references,so you have to box primitive values into the appropriate wrapper classes( Integer,Float etc.).When you take the object out of the collection, you get the Integer that you put in; if you need an int, you must unbox the Integer using the intValue method. this boxing and unboxing is a pain,and clutters up your code.tHe Autoboxing and Unboxing feature automates the process.


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Applying for a job can be a stressful and frustrating experience, especially for someone who has never done it before. Considering that you are competing for the position with a at least a dozen other applicants, it is imperative that you thoroughly prepare for the job interview, in order to stand a good chance of getting hired. That's where GeekInterview can help.
Interact