It is sometimes necessary to create a class object before creating any instances of the class. For example, creating instances using the <className> Renew macro or the somRenew method requires knowing how large the created instance will be, so that memory can be allocated for it. Getting this information requires creating the class object (see the example under "Creating instances of a class" early in this chapter). As another example, a class object must be explicitly created when a program does not use the SOM bindings for a class. Without SOM bindings for a class, its instances must be created using somNew or somRenew, and these methods require that the class object be created in advance.

Use the <className>NewClass procedure to create a class object:


[Back] [Next]