OBJECT
The OBJECT data type is a WMI class object use to declare weakly typed associations and embedded objects. You do not define the specific class for a weakly typed object until you create an instance of the class. Embedded objects defined with the OBJECT data type can contain instances of any WMI class. For more information, see Embedded Objects.
The following example defines and creates instances of two classes, one of which contains an embedded object of type OBJECT:
#pragma namespace("\\\\.\\root")
instance of __Namespace
{
Name = "WMI" ;
} ;
#pragma namespace("\\\\.\\root\\WMI")
class CompositeClass
{
[key] string aKey;
object EmbObj; // Weakly typed
};
class EmbClass
{
[key] string aKey;
};
instance of CompositeClass
{
aKey = "CompositeClass Key";
EmbObj =
instance of EmbClass
{
aKey = "key for embedded object";
};
};
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for