(file) Return to CIMInstance.cpp CVS log (file) (dir) Up to [Pegasus] / pegasus / src / Pegasus / Common

Diff for /pegasus/src/Pegasus/Common/CIMInstance.cpp between version 1.24 and 1.30

version 1.24, 2002/05/23 16:52:16 version 1.30, 2002/08/14 17:41:16
Line 1 
Line 1 
 //%///////////////////////////////////////////////////////////////////////////// //%/////////////////////////////////////////////////////////////////////////////
 // //
 // 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
Line 67 
Line 68 
     Inc(_rep);     Inc(_rep);
 } }
  
 CIMInstance::CIMInstance(const String& className)  CIMInstance::CIMInstance(const CIMName& className)
 { {
     _rep = new CIMInstanceRep(className);      _rep = new CIMInstanceRep(CIMObjectPath(String::EMPTY, CIMNamespaceName(), className));
 } }
  
 CIMInstance::CIMInstance(CIMInstanceRep* rep) CIMInstance::CIMInstance(CIMInstanceRep* rep)
Line 92 
Line 93 
     Dec(_rep);     Dec(_rep);
 } }
  
 const String& CIMInstance::getClassName() const  const CIMName& CIMInstance::getClassName() const
 { {
     _checkRep();     _checkRep();
     return _rep->getClassName();     return _rep->getClassName();
Line 117 
Line 118 
     return *this;     return *this;
 } }
  
 Uint32 CIMInstance::findQualifier(const String& name) const  Uint32 CIMInstance::findQualifier(const CIMName& name) const
 { {
     _checkRep();     _checkRep();
     return _rep->findQualifier(name);     return _rep->findQualifier(name);
 } }
  
 Boolean CIMInstance::existsQualifier(const String& name) const  
 {  
     _checkRep();  
     return _rep->existsQualifier(name);  
 }  
   
 CIMQualifier CIMInstance::getQualifier(Uint32 pos) CIMQualifier CIMInstance::getQualifier(Uint32 pos)
 { {
     _checkRep();     _checkRep();
Line 154 
Line 149 
     return *this;     return *this;
 } }
  
 Uint32 CIMInstance::findProperty(const String& name) const  Uint32 CIMInstance::findProperty(const CIMName& name) const
 { {
     _checkRep();     _checkRep();
     return _rep->findProperty(name);     return _rep->findProperty(name);
 } }
  
 Boolean CIMInstance::existsProperty(const String& name) const  
 {  
    _checkRep();  
    return _rep->existsProperty(name);  
 }  
   
 CIMProperty CIMInstance::getProperty(Uint32 pos) throw(OutOfBounds) CIMProperty CIMInstance::getProperty(Uint32 pos) throw(OutOfBounds)
 { {
     _checkRep();     _checkRep();
Line 190 
Line 179 
     return _rep->getPropertyCount();     return _rep->getPropertyCount();
 } }
  
 Boolean CIMInstance::isNull() const  Boolean CIMInstance::isUninitialized() const
 { {
     return (_rep == 0)? true : false;     return (_rep == 0)? true : false;
 } }
Line 202 
Line 191 
     return _rep->identical(x._rep);     return _rep->identical(x._rep);
 } }
  
 void CIMInstance::resolve(  
     DeclContext* declContext,  
     const String& nameSpace,  
     Boolean propagateQualifiers)  
 {  
     _checkRep();  
     CIMConstClass cimClass;  
     _rep->resolve(declContext, nameSpace, cimClass, propagateQualifiers);  
 }  
   
 void CIMInstance::resolve(  
     DeclContext* declContext,  
     const String& nameSpace,  
     CIMConstClass& cimClassOut,  
     Boolean propagateQualifiers)  
 {  
     _checkRep();  
     _rep->resolve(declContext, nameSpace, cimClassOut, propagateQualifiers);  
 }  
   
 CIMInstance CIMInstance::clone() const CIMInstance CIMInstance::clone() const
 { {
     return CIMInstance((CIMInstanceRep*)(_rep->clone()));     return CIMInstance((CIMInstanceRep*)(_rep->clone()));
 } }
  
 CIMObjectPath CIMInstance::getInstanceName(const CIMConstClass& cimClass) const  CIMObjectPath CIMInstance::buildPath(const CIMConstClass& cimClass) const
 { {
     _checkRep();     _checkRep();
     return _rep->getInstanceName(cimClass);      return _rep->buildPath(cimClass);
 } }
  
 String CIMInstance::toString() const String CIMInstance::toString() const
Line 242 
Line 211 
 void CIMInstance::_checkRep() const void CIMInstance::_checkRep() const
 { {
     if (!_rep)     if (!_rep)
         ThrowUninitializedHandle();          ThrowUninitializedObject();
 } }
  
 //////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
Line 281 
Line 250 
     Inc(_rep);     Inc(_rep);
 } }
  
 CIMConstInstance::CIMConstInstance(const String& className)  CIMConstInstance::CIMConstInstance(const CIMName& className)
 { {
     _rep = new CIMInstanceRep(className);      _rep = new CIMInstanceRep(CIMObjectPath(String::EMPTY, CIMNamespaceName(), className));
 } }
  
 CIMConstInstance& CIMConstInstance::operator=(const CIMConstInstance& x) CIMConstInstance& CIMConstInstance::operator=(const CIMConstInstance& x)
Line 311 
Line 280 
     Dec(_rep);     Dec(_rep);
 } }
  
 const String& CIMConstInstance::getClassName() const  const CIMName& CIMConstInstance::getClassName() const
 { {
     _checkRep();     _checkRep();
     return _rep->getClassName();     return _rep->getClassName();
Line 323 
Line 292 
     return _rep->getPath();     return _rep->getPath();
 } }
  
 Uint32 CIMConstInstance::findQualifier(const String& name) const  Uint32 CIMConstInstance::findQualifier(const CIMName& name) const
 { {
     _checkRep();     _checkRep();
     return _rep->findQualifier(name);     return _rep->findQualifier(name);
Line 341 
Line 310 
     return _rep->getQualifierCount();     return _rep->getQualifierCount();
 } }
  
 Uint32 CIMConstInstance::findProperty(const String& name) const  Uint32 CIMConstInstance::findProperty(const CIMName& name) const
 { {
     _checkRep();     _checkRep();
     return _rep->findProperty(name);     return _rep->findProperty(name);
Line 359 
Line 328 
     return _rep->getPropertyCount();     return _rep->getPropertyCount();
 } }
  
 Boolean CIMConstInstance::isNull() const  Boolean CIMConstInstance::isUninitialized() const
 { {
     return (_rep == 0)? true : false;     return (_rep == 0)? true : false;
 } }
Line 376 
Line 345 
     return CIMInstance((CIMInstanceRep*)(_rep->clone()));     return CIMInstance((CIMInstanceRep*)(_rep->clone()));
 } }
  
 CIMObjectPath CIMConstInstance::getInstanceName(const CIMConstClass& cimClass) const  CIMObjectPath CIMConstInstance::buildPath(const CIMConstClass& cimClass) const
 { {
     _checkRep();     _checkRep();
     return _rep->getInstanceName(cimClass);      return _rep->buildPath(cimClass);
 } }
  
 String CIMConstInstance::toString() const String CIMConstInstance::toString() const
Line 391 
Line 360 
 void CIMConstInstance::_checkRep() const void CIMConstInstance::_checkRep() const
 { {
     if (!_rep)     if (!_rep)
         ThrowUninitializedHandle();          ThrowUninitializedObject();
 }  
   
   
 Boolean operator==(const CIMInstance& x, const CIMInstance& y)  
 {  
     return x.identical(y);  
 } }
  
 PEGASUS_NAMESPACE_END PEGASUS_NAMESPACE_END


Legend:
Removed from v.1.24  
changed lines
  Added in v.1.30

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2