In cim_obj.py, there are several issues in the representation of classes and qualifier declarations as MOF:
Some characters that require backslash escaping in MOF are not escaped: \n, \r, \t, \"
Reference typed properties and parameters are declared as 'reference'; the class name is missing. Correct would be '<classname> REF'.</classname>
In the specification of default values for array-typed qualifier declarations, the "=" is missing.
An empty line could be added before each property and method within a class declarations, for better readability.
More issues:
Representation of arrays misses the []
Qualifiers of method parameters are missing
The order of qualifiers could be sorted by qualifier name instead of being the rather arbitrary dictionary iteration order.
Fixed all of these issues in cim_obj.py
Added test code for the new mofstr() function to test_cim_obj.py.
Committed these changes as r712.