Search results
Results From The WOW.Com Content Network
In computer science, boxing (a.k.a. wrapping) is the transformation of placing a primitive type within an object so that the value can be used as a reference. Unboxing is the reverse transformation of extracting the primitive value from its wrapper object. Autoboxing is the term for automatically applying boxing and/or unboxing transformations ...
Primitive wrapper classes are not the same thing as primitive types. Whereas variables, for example, can be declared in Java as data types double, short, int, etc., the primitive wrapper classes create instantiated objects and methods that inherit but hide the primitive data types, not like variables that are assigned the data type values.
So, the simplest solution, I guess, is to rename it. But I'm afraid the name Boxing, unboxing and autoboxing may narrow the scope of the article too much. The article starts with saying that an object type is a datatype, and so it should be about a general concept, mentioning boxing of a primitive data type as one example, not as a primary subject.
For example, a simple linearized object would consist of a length field, a code point identifying the class, and a data value. A more complex example would be a command consisting of the length and code point of the command and values consisting of linearized objects representing the command's parameters.
Comparison of C Sharp and Java; Class (computer programming) Closure (computer programming) Command pattern; Command-line argument parsing; Comment (computer programming) Comparison of programming languages (algebraic data type) Composite entity pattern; Composite pattern; Conditional operator; Constant (computer programming) Continuation ...
This comparison of programming languages compares how object-oriented programming languages such as C++, Java, Smalltalk, Object Pascal, Perl, Python, and others manipulate data structures. Object construction and destruction
Get AOL Mail for FREE! Manage your email like never before with travel, photo & document views. Personalize your inbox with themes & tabs. You've Got Mail!
The following example illustrates the different behavior. In C#, the lifted*operator propagates the null value of the operand; in Java, unboxing the null reference throws an exception. Not all C# lifted operators have been defined to propagate null unconditionally, if one of the operands is null.