Value type

Value type

In object-oriented programming, a value type is a data type that can exist outside dynamic memory allocation. Unlike reference types, value types can be directly embedded into composite objects.

Primitive types are always value types.

Value types can exist in dynamically allocated memory, such as embedded into a dynamic object. Some platforms also allow direct dynamic allocation of value objects, while others require the value to be copied into a specific dynamic object. The later process is called boxing.

On some platforms, a value may be directly linked to by a pointer or reference. On others, it is a prerogative or reference types.

Language support

* In Java, the only value types are the primitive types. A primitive type cannot be dynamically created on its own, so the class library provides primitive wrapper classes.
* As C++ has no built-in support for reference types, all types can be assumed to be value types (although reference type behavior can be emulated by restricting access to a type's constructor). C++ supports direct allocation and referencing of all values.
* The .NET Framework allows user-defined and complex value types, as well as boxing of any value type.


Wikimedia Foundation. 2010.

Игры ⚽ Поможем написать реферат

Look at other dictionaries:

  • Type system — Type systems Type safety Inferred vs. Manifest Dynamic vs. Static Strong vs. Weak Nominal vs. Structural Dependent typing Duck typing Latent typing Linear typing Uniqueness typing …   Wikipedia

  • Value theory — encompasses a range of approaches to understanding how, why and to what degree people should value things; whether the thing is a person, idea, object, or anything else. This investigation began in ancient philosophy, where it is called axiology… …   Wikipedia

  • Type inference — Type inference, or implicit typing, refers to the ability to deduce automatically the type of a value in a programming language. It is a feature present in some strongly statically typed languages. It is often characteristic of but not limited to …   Wikipedia

  • Value network analysis — is a methodology for understanding, using, visualizing, optimizing internal and external value networks and complex economic ecosystems. The methods include visualizing sets of relationships from a dynamic whole systems perspective. Robust… …   Wikipedia

  • Value capture — refers to a type of innovative public financing in which increases in private land values generated by a new public investment are all or in part “captured” through a land related tax to pay for that investment or other public projects. Value… …   Wikipedia

  • Value Stream Mapping — is a Lean technique used to analyse the flow of materials and information currently required to bring a product or service to a consumer. At Toyota, where the technique originated, it is known as Material and Information Flow Mapping [Learning to …   Wikipedia

  • Value conversion — is the act of converting one type of value or financial instrument into another type of negotiable value. In the securities profession the definition of conversion value is very narrowly defined as the positive difference between the market price …   Wikipedia

  • Value change dump — is an ASCII based format for dumpfiles generated by EDA logic simulation tools. The standard, four value VCD format was defined along with the Verilog hardware description language by the IEEE Standard 1364 1995 in 1995. An Extended VCD format… …   Wikipedia

  • Value-based pricing — Value based pricing, or Value optimized pricing is a business strategy. It sets selling prices primarily, but not exclusively, on the perceived value to the customer, rather than on the actual cost of the product, the market price, competitors… …   Wikipedia

  • Value stream mapping software — is a type of software that helps prepare and/or analyze value stream maps. The software typically helps design maps through utilizing a series of symbols representing activity and information/material flow, and as a supplement to manual… …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”