Value types in ABL
- Last Updated: April 10, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
Value types in ABL
These are all the types that derive from the .NET System.ValueType class.
They include a specific set of classes—all structures and enumerations.
Value types differ from all other .NET object types in that
they are passed to or returned from .NET by value. This has implications
for managing value type objects in ABL. For more information, see Support for .NET object types.
.NET actually implements most primitive data types of .NET languages
as their interchangeable subset of value types in the CLR—for example, System.Boolean,
which implements the C# bool, and System.Double,
which implements the C# double. An ABL application,
then, accesses these .NET mapped data types through public .NET method
parameters, properties, or data members using corresponding built-in
ABL primitive types. For example, ABL maps its LOGICAL to System.Boolean and
maps its DECIMAL to System.Double. However,
unlike CLS-compliant languages whose primitive types mostly map one-to-one
with their interchangeable object-type equivalents, ABL has fewer corresponding
primitive types and supports its own mappings by doing appropriate
compile-time and run-time type compatibility checking.