void CIMClassPathtoXML(CIMObjectPath const& cop, ostream& ostr) { if (!cop.isClassPath()) { OW_THROWCIMMSG(CIMException::INVALID_PARAMETER, "cop is an instance path, not a class path as expected."); } if (!cop.getNameSpace().empty()) { // do <CLASSPATH> ostr << "<CLASSPATH>"; CIMNameSpacetoXML(cop.getFullNameSpace(),ostr); ostr << "<CLASSNAME NAME=\"" << cop.getClassName() << "\"/></CLASSPATH>"; } else { // do <CLASSNAME> ostr << "<CLASSNAME NAME=\"" << cop.getClassName() << "\"/>"; } }