Now that the basic structure of the classes is complete, we can think about the properties we need to add to them. Because this is a much simpler exercise than choosing and positioning classes, and one where errors can be easily corrected, I will not go into as much detail here. I will, however, choose a single class, ACNE_PBXTelephoneModule, and consider the types of property it might have. This will allow me to use this class as as example when writing a provider for it in Chapter 12. The mof defining this class is included in that chapter as Figure 12.1 on page 216.
This class was designed to represent the logical view of the telephone interface card (rather than its physical view). As such it might have properties such as the following (note that (*) indicates that a client may modify the property):
uint32 Protocol; // European, N.America, etc. (*)
These, of course, are in addition to the property it inherits from CIM_LogicalModule:
uint16 ModuleNumber; // slot number
and those which it indirectly inherits from CIM_LogicalDevice:
string SystemCreationClassName; // Key string SystemName; // Key string CreationClassName; // Key string DeviceID; // Key uint32 Reset(); // reset device uint32 SaveProperties(); // save state uint32 RestoreProperties(); // restore saved state
and those which it inherits from CIM_ManagedSystemElement (CIM_LogicalElement contains no properties):
datetime InstallDate; string Name; uint16 OperationalStatus; // degraded, stressed, etc. string StatusDescriptions; // info about status
and, highest of all in the tree, the properties it inherits from CIM_ManagedElement:
string Caption; // description of the object (*) string Description; // description of the object (*) string ElementName; // user-friendly name (*)
Because this is a pedagogical example which I will be using later to demonstrate how to write providers, it would be useful also to have a couple of extrinsic methods . To this end I will therefore assume that the logical device has some form of indicator (an LED on the front-plate perhaps) which can be lit and extinguished on demand. The associated method is:
Boolean setIndicator(Boolean newValue);
This method accepts a single Boolean parameter and sets the indicator on (true) or off (false), returning the previous value of the indicator.
Over the course of the this chapter, I have addressed some of the technical and commercial points that you will need to consider when building a model. I have sketched the outline of a model for a very simple PBX. In Chapter 12, I look at designing and coding some of the providers for this PBX.