version 1.10, 2001/12/13 14:53:54
|
version 1.18, 2002/05/15 10:34:28
|
|
|
// | // |
//%///////////////////////////////////////////////////////////////////////////// | //%///////////////////////////////////////////////////////////////////////////// |
| |
|
#include <Pegasus/Common/Config.h> |
#include <cstdio> | #include <cstdio> |
#include "CIMParameter.h" | #include "CIMParameter.h" |
|
#include "CIMParameterRep.h" |
#include "Indentor.h" | #include "Indentor.h" |
#include "CIMName.h" | #include "CIMName.h" |
#include "CIMScope.h" | #include "CIMScope.h" |
|
|
nameSpace, | nameSpace, |
CIMScope::PARAMETER, | CIMScope::PARAMETER, |
false, | false, |
dummy); |
dummy, |
|
true); |
} | } |
| |
void CIMParameterRep::toXml(Array<Sint8>& out) const | void CIMParameterRep::toXml(Array<Sint8>& out) const |
|
|
| |
out << " NAME=\"" << _name << "\" "; | out << " NAME=\"" << _name << "\" "; |
| |
out << " TYPE=\"" << TypeToString(_type) << "\""; |
out << " TYPE=\"" << _type.toString() << "\""; |
| |
if (_arraySize) | if (_arraySize) |
{ | { |
|
|
{ | { |
out << "<PARAMETER"; | out << "<PARAMETER"; |
out << " NAME=\"" << _name << "\" "; | out << " NAME=\"" << _name << "\" "; |
out << " TYPE=\"" << TypeToString(_type) << "\""; |
out << " TYPE=\"" << _type.toString() << "\""; |
out << ">\n"; | out << ">\n"; |
| |
_qualifiers.toXml(out); | _qualifiers.toXml(out); |
|
|
out << " "; | out << " "; |
| |
// Output the data type and name | // Output the data type and name |
out << TypeToString(_type) << " " << _name; |
out << _type.toString() << " " << _name; |
| |
if (_isArray) | if (_isArray) |
{ | { |
|
|
} | } |
| |
| |
void CIMParameterRep::print(PEGASUS_STD(ostream) &os) const |
|
{ |
|
Array<Sint8> tmp; |
|
toXml(tmp); |
|
tmp.append('\0'); |
|
os << tmp.getData() << PEGASUS_STD(endl); |
|
} |
|
|
|
Boolean CIMParameterRep::identical(const CIMParameterRep* x) const | Boolean CIMParameterRep::identical(const CIMParameterRep* x) const |
{ | { |
if (_name != x->_name) | if (_name != x->_name) |
|
|
x._qualifiers.cloneTo(_qualifiers); | x._qualifiers.cloneTo(_qualifiers); |
} | } |
| |
CIMParameterRep& CIMParameterRep::operator=(const CIMParameterRep& x) |
|
{ |
|
return *this; |
|
} |
|
|
|
void CIMParameterRep::setType(CIMType type) | void CIMParameterRep::setType(CIMType type) |
{ | { |
_type = type; | _type = type; |