version 1.10, 2002/05/07 00:00:35
|
version 1.17, 2002/07/30 16:14:53
|
|
|
//%///////////////////////////////////////////////////////////////////////////// | //%///////////////////////////////////////////////////////////////////////////// |
// | // |
// Copyright (c) 2000, 2001 The Open group, BMC Software, Tivoli Systems, IBM |
// Copyright (c) 2000, 2001, 2002 BMC Software, Hewlett-Packard Company, IBM, |
|
// The Open Group, Tivoli Systems |
// | // |
// Permission is hereby granted, free of charge, to any person obtaining a copy | // Permission is hereby granted, free of charge, to any person obtaining a copy |
// of this software and associated documentation files (the "Software"), to | // of this software and associated documentation files (the "Software"), to |
|
|
// Author: Mike Brasher (mbrasher@bmc.com) | // Author: Mike Brasher (mbrasher@bmc.com) |
// | // |
// Modified By: Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com) | // Modified By: Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com) |
|
// Carol Ann Krug Graves, Hewlett-Packard Company |
|
// (carolann_graves@hp.com) |
// | // |
//%///////////////////////////////////////////////////////////////////////////// | //%///////////////////////////////////////////////////////////////////////////// |
| |
|
|
} | } |
| |
CIMParameter::CIMParameter( | CIMParameter::CIMParameter( |
const String& name, |
const CIMName& name, |
CIMType type, | CIMType type, |
Boolean isArray, | Boolean isArray, |
Uint32 arraySize, | Uint32 arraySize, |
const String& referenceClassName) |
const CIMName& referenceClassName) |
{ | { |
_rep = new CIMParameterRep( | _rep = new CIMParameterRep( |
name, type, isArray, arraySize, referenceClassName); | name, type, isArray, arraySize, referenceClassName); |
|
|
return *this; | return *this; |
} | } |
| |
const String& CIMParameter::getName() const |
const CIMName& CIMParameter::getName() const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->getName(); | return _rep->getName(); |
} | } |
| |
void CIMParameter::setName(const String& name) |
void CIMParameter::setName(const CIMName& name) |
{ | { |
_checkRep(); | _checkRep(); |
_rep->setName(name); | _rep->setName(name); |
|
|
return _rep->getArraySize(); | return _rep->getArraySize(); |
} | } |
| |
const String& CIMParameter::getReferenceClassName() const |
const CIMName& CIMParameter::getReferenceClassName() const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->getReferenceClassName(); | return _rep->getReferenceClassName(); |
|
|
return *this; | return *this; |
} | } |
| |
Uint32 CIMParameter::findQualifier(const String& name) const |
Uint32 CIMParameter::findQualifier(const CIMName& name) const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->findQualifier(name); | return _rep->findQualifier(name); |
|
|
return _rep->getQualifierCount(); | return _rep->getQualifierCount(); |
} | } |
| |
void CIMParameter::resolve(DeclContext* declContext, const String& nameSpace) |
Boolean CIMParameter::isNull() const |
{ | { |
_checkRep(); |
return (_rep == 0)? true : false; |
_rep->resolve(declContext, nameSpace); |
|
} |
|
|
|
CIMParameter::operator int() const |
|
{ |
|
return (_rep != 0); |
|
} |
|
|
|
void CIMParameter::toXml(Array<Sint8>& out) const |
|
{ |
|
_checkRep(); |
|
_rep->toXml(out); |
|
} |
|
|
|
void CIMParameter::toMof(Array<Sint8>& out) const |
|
{ |
|
_checkRep(); |
|
_rep->toMof(out); |
|
} |
|
|
|
void CIMParameter::print(PEGASUS_STD(ostream)& o) const |
|
{ |
|
_checkRep(); |
|
_rep->print(o); |
|
} | } |
| |
Boolean CIMParameter::identical(const CIMConstParameter& x) const | Boolean CIMParameter::identical(const CIMConstParameter& x) const |
|
|
void CIMParameter::_checkRep() const | void CIMParameter::_checkRep() const |
{ | { |
if (!_rep) | if (!_rep) |
ThrowUnitializedHandle(); |
ThrowUninitializedHandle(); |
} | } |
| |
| |
|
|
} | } |
| |
CIMConstParameter::CIMConstParameter( | CIMConstParameter::CIMConstParameter( |
const String& name, |
const CIMName& name, |
CIMType type, | CIMType type, |
Boolean isArray, | Boolean isArray, |
Uint32 arraySize, | Uint32 arraySize, |
const String& referenceClassName) |
const CIMName& referenceClassName) |
{ | { |
_rep = new CIMParameterRep( | _rep = new CIMParameterRep( |
name, type, isArray, arraySize, referenceClassName); | name, type, isArray, arraySize, referenceClassName); |
|
|
return *this; | return *this; |
} | } |
| |
const String& CIMConstParameter::getName() const |
const CIMName& CIMConstParameter::getName() const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->getName(); | return _rep->getName(); |
|
|
return _rep->getArraySize(); | return _rep->getArraySize(); |
} | } |
| |
const String& CIMConstParameter::getReferenceClassName() const |
const CIMName& CIMConstParameter::getReferenceClassName() const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->getReferenceClassName(); | return _rep->getReferenceClassName(); |
|
|
return _rep->getType(); | return _rep->getType(); |
} | } |
| |
Uint32 CIMConstParameter::findQualifier(const String& name) const |
Uint32 CIMConstParameter::findQualifier(const CIMName& name) const |
{ | { |
_checkRep(); | _checkRep(); |
return _rep->findQualifier(name); | return _rep->findQualifier(name); |
|
|
return _rep->getQualifierCount(); | return _rep->getQualifierCount(); |
} | } |
| |
CIMConstParameter::operator int() const |
Boolean CIMConstParameter::isNull() const |
{ |
|
return (_rep != 0); |
|
} |
|
|
|
void CIMConstParameter::toXml(Array<Sint8>& out) const |
|
{ |
|
_checkRep(); |
|
_rep->toXml(out); |
|
} |
|
|
|
void CIMConstParameter::print(PEGASUS_STD(ostream)& o) const |
|
{ | { |
_checkRep(); |
return (_rep == 0)? true : false; |
_rep->print(o); |
|
} | } |
| |
Boolean CIMConstParameter::identical(const CIMConstParameter& x) const | Boolean CIMConstParameter::identical(const CIMConstParameter& x) const |
|
|
void CIMConstParameter::_checkRep() const | void CIMConstParameter::_checkRep() const |
{ | { |
if (!_rep) | if (!_rep) |
ThrowUnitializedHandle(); |
ThrowUninitializedHandle(); |
} | } |
| |
PEGASUS_NAMESPACE_END | PEGASUS_NAMESPACE_END |