System::BoxedValue class

BoxedValue class

Represents a boxed value. Objects of this class should only be allocated using System::MakeObject() function. Never create instance of this type on stack or using operator new, as it will result in runtime errors and/or assertion faults. Always wrap this class into System::SmartPtr pointer and use this pointer to pass it to functions as argument.

template<class T>class BoxedValue : public System::BoxedValueBase
ParameterDescription
TType of the boxed value represented by the class

Methods

MethodDescription
BoxedValue(const T&)Constructs an object that represents the specified value boxed.
Equals(ptr) overrideDetermines the equality of the boxed values represented by the current and specified objects.
GetHashCode() const overrideReturns a hash code for the current object.
GetType() const overrideGets actual type of object.
GetTypeCode() const overrideReturns the value representing the type of the boxed value represented by the current object.
GetUnsignedLongLongValue() overrideAlways returns 0.
is() constDetermines if the type of the boxed value represented by the current object is V.
IsBoxedEnum() overrideDetermines if current object represents a boxed value of enum type.
static Parse(const TypeInfo&, const String&, bool)Boxes the value of enumeration constant of the specified enumeration with the specified name. A parameter specifies if the case should be ignored when interpreting the string specifying the name of the enumeration constant.
static Parse(const TypeInfo&, const String&)Boxes the value of enumeration constant of the specified enumeration with the specified name.
ToString() const overrideConverts boxed value represented by current object to string.
unbox() constUnboxes the value represented by the current object.

See Also