Wednesday, 18 January 2012
JAVA: Wrapper class
Do you like this Article?
Wrapper class is a special type of class that's used to make primitive variables into objects, so that the primitives can be included in activities reserved for objects, like as being added to Collections, or returned from a method with an object return value. It simply wraps or encapsulates a single value for the primitive data types. These classes contain methods that provide basic functions such as class conversion, value testing & equality checks and the constructors of wrapper classes, allow objects can create and convert primitives to and from String objects.
LIST OF WRAPPER CLASS
LIST OF WRAPPER CLASS
Primitive type
|
Wrapper class
| |
1
|
boolean
|
Java.lang.Boolean
|
2
|
byte
|
Java.lang.Byte
|
3
|
char
|
Java.lang.Char
|
4
|
double
|
Java.lang.Double
|
5
|
float
|
Java.lang.Float
|
6
|
int
|
Java.lang.Int
|
7
|
long
|
Java.lang.Long
|
8
|
short
|
Java.lang.Short
|
Subscribe to:
Post Comments
(
Atom
)
Popular Posts
-
public - public means everyone can access it.That means it's in global scope. As, main method is called by JVM [ Java Virtual Machine...
-
throw is used to throw an exception in a program, explicitly . Whereas, throws is included in the method's declaration part, wi...
-
Singleton in one of the most popular yet controversial design pattern, in the world of object oriented programming. It's one of t...
-
Web Container / Servlet Container / Servlet Engine : In J2EE Architecture , a web container (also known as servlet container or ser...
-
Program compiles. But at runtime throws an error “NoSuchMethodError”.
-
Vector : It's synchronized. It's slower than ArrayList. It's generally used in ...
-
doGet(): protected void doGet(HttpServletRequest req, HttpServletResponse resp)throws ServletException, java.io.IOException – is a met...
-
In Java Programming Language , we must declare a variable name and type, before using it. The data type of a variable defines the th...
10 Responses to “ JAVA: Wrapper class ”
22 December 2012 at 16:58
As we know that JAVA is a pure Object Oriented programming language. But the primitive data type breaks these feature. Bcz primitive data type doesn't use class and object. To overcome this problem The Wrapper class is written, which convert or create the variable in the form of Object. So that JAVA can be said as a pure Object Oriented programming language.
http://www.coolinterview.com/interview/18011/
27 August 2013 at 13:29
This is really a great read for me. Thank you for publishing articles having a great insight stimulates me to check more often for new write ups. Keep posting!
Clover
www.n8fan.net
4 February 2015 at 08:16
Hi, I hope you have a good day. Thank you for inspiring us. You bring joy to our face.visit my site if you have time.
kieth
www.n8fan.net
1 May 2017 at 15:13 This comment has been removed by the author.
25 May 2017 at 15:56
this is really very useful post about wrapper class
thank you so much for this post.
22 August 2017 at 15:43
Thanks for a great information in your blog. I have read all the post of your blog.
Regards,
Java Online Training | Java Online Training in India | Java Online Training India | Java Online Training in Hyderabad | Java Online Training Hyderabad | Java Training in Hyderabad | Java Training in India | Java Training Institutes in India | Java Training Institutes in Hyderabad | Java Course in Hyderabad | Java Training | Learn Java Online | Online Java Training | Best Java online Training Institutes in Hyderabad | Best Java Training Institutes in Hyderabad | Best Institutes for Java | Java Institutes in Hyderabad | Best Institutes for Java in Hyderabad | Learn Java | Java Training Institutes in Hyderabad | Java Certification | Java Certification Training | Java Certification Training in Hyderabad | Java Certification Training in India
24 January 2018 at 14:53
Thank you for this brief explanation and ver nice information. well, got a good knowledge. Have a nice idea, this is more helpful to me. This can gives the better performance.
Java training in Chennai||
J2ee training in Chennai
20 April 2018 at 13:16
Hi There,
Amaze! I have been looking Bing for hours because of this and I also in the end think it is in this article! Maybe I recommend you something helps me all the time?
This may well belong in the New to Java section but I keep getting logged out every time I enter that forum.
I am creating code to issue tickets to passengers on 4 different bus routes, I am going to contain them in an array.
Although, I have hit a wall in writing this code and I am stumped. I will post the 3 classes I have so far and the error I am getting.
Lots of optimization can be done around String, as this object is most used object in almost all applications. String pool provided by JVM can be used judiciously. However, there are some concerns.
Also, I would welcome any sort of guidance or recommendations.
Awesome! Thanks for putting this all in one place. Very useful!
Thank you,
Alex
10 August 2018 at 13:29
Love this blog. Keep posting articles like this. java training in chennai
4 February 2019 at 15:04
Useful information. Thanks for sharing.
Interview Guidance
Post a Comment