2.2.71 EncodedValue

EncodedValue is an encoded value that is used everywhere to represent numerical and string values.

If the value is of type CIM-TYPE-SINT8, CIM-TYPE-UINT8, CIM-TYPE-SINT16, CIM-TYPE-UINT16, CIM-TYPE-SINT32, CIM-TYPE-UINT32, CIM-TYPE-SINT64, CIM-TYPE-UINT64, CIM-TYPE-REAL32 or CIM-TYPE-REAL64 as defined in CimType (section 2.2.82), the EncodedValue is inline as defined in NumericValue (section 2.2.72).

If the value is of type CIM-TYPE-CHAR16, the EncodedValue is a 16-bit value stored as a CIM-TYPE-SINT16.

If the value is of type CIM-TYPE-BOOLEAN, the encoded value is inline as defined in BOOL (section 2.2.75).

If the value is of type CIM-TYPE-STRING, CIM-TYPE-DATETIME, or CIM-TYPE-REFERENCE, the EncodedValue is a HeapRef (section 2.2.69) to that Encoded-String. The value of types CIM-TYPE-DATETIME and CIM-TYPE-REFERENCE are encoded as strings, as specified in 2.3.1 and 2.3.2 respectively.

If the value type is CimArrayType, the EncodedValue is a HeapRef to the Encoded-Array.

If the value type is CIM-TYPE-OBJECT, the EncodedValue is a HeapRef to the object encoded as an ObjectEncodingLength (section 2.2.4) followed by an ObjectBlock (section 2.2.5).

While encoding a class, if a property defined for the class does not have a default value in the class, the OCTETs reserved for the property in the ValueTable MUST be filled with NoValue (section 2.2.74). The number of OCTETs reserved for a property without a default value MUST be equal to the size required for the property type as defined above.

 EncodedValue = NumericValue / HeapRef / BOOL / NoValue