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

Diff for /pegasus/src/Pegasus/Common/CIMParameter.h between version 1.15 and 1.16

version 1.15, 2002/02/22 22:50:07 version 1.16, 2002/05/07 00:00:35
Line 22 
Line 22 
 // //
 // Author: Mike Brasher (mbrasher@bmc.com) // Author: Mike Brasher (mbrasher@bmc.com)
 // //
 // Modified By:  // Modified By: Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com)
 // //
 //%///////////////////////////////////////////////////////////////////////////// //%/////////////////////////////////////////////////////////////////////////////
  
Line 30 
Line 30 
 #define Pegasus_Parameter_h #define Pegasus_Parameter_h
  
 #include <Pegasus/Common/Config.h> #include <Pegasus/Common/Config.h>
 #include <Pegasus/Common/CIMParameterRep.h>  #include <Pegasus/Common/CIMQualifier.h>
   #include <Pegasus/Common/CIMType.h>
  
 PEGASUS_NAMESPACE_BEGIN PEGASUS_NAMESPACE_BEGIN
  
Line 40 
Line 41 
 // //
 //////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
  
   class DeclContext;
 class CIMConstParameter; class CIMConstParameter;
   class CIMParameterRep;
  
 class PEGASUS_COMMON_LINKAGE CIMParameter class PEGASUS_COMMON_LINKAGE CIMParameter
 { {
 public: public:
  
     CIMParameter() : _rep(0)      CIMParameter();
     {  
   
     }  
   
     CIMParameter(const CIMParameter& x)  
     {  
         Inc(_rep = x._rep);  
     }  
  
     CIMParameter& operator=(const CIMParameter& x)      CIMParameter(const CIMParameter& x);
     {  
         if (x._rep != _rep)  
         {  
             Dec(_rep);  
             Inc(_rep = x._rep);  
         }  
         return *this;  
     }  
  
     // Throws IllegalName if name argument not legal CIM identifier.     // Throws IllegalName if name argument not legal CIM identifier.
   
     CIMParameter(     CIMParameter(
         const String& name,         const String& name,
         CIMType type,         CIMType type,
         Boolean isArray = false,         Boolean isArray = false,
         Uint32 arraySize = 0,         Uint32 arraySize = 0,
         const String& referenceClassName = String::EMPTY)          const String& referenceClassName = String::EMPTY);
     {  
         _rep = new CIMParameterRep(  
             name, type, isArray, arraySize, referenceClassName);  
     }  
  
     ~CIMParameter()      ~CIMParameter();
     {  
         Dec(_rep);  
     }  
   
     const String& getName() const  
     {  
         _checkRep();  
         return _rep->getName();  
     }  
  
     // Throws IllegalName if name argument not legal CIM identifier.      CIMParameter& operator=(const CIMParameter& x);
  
     void setName(const String& name)      const String& getName() const ;
     {  
         _checkRep();  
         _rep->setName(name);  
     }  
  
     Boolean isArray() const      // Throws IllegalName if name argument not legal CIM identifier.
     {      void setName(const String& name);
         _checkRep();  
         return _rep->isArray();  
     }  
  
     Uint32 getArraySize() const      Boolean isArray() const;
     {  
         _checkRep();  
         return _rep->getArraySize();  
     }  
  
     const String& getReferenceClassName() const      Uint32 getArraySize() const;
     {  
         _checkRep();  
         return _rep->getReferenceClassName();  
     }  
  
     CIMType getType() const      const String& getReferenceClassName() const ;
     {  
         _checkRep();  
         return _rep->getType();  
     }  
  
     void setType(const CIMType type)      CIMType getType() const ;
     {  
         _checkRep();  
         _rep->setType(type);  
     }  
  
       void setType(const CIMType type);
  
     // Throws AlreadyExists.     // Throws AlreadyExists.
       CIMParameter& addQualifier(const CIMQualifier& x);
  
     CIMParameter& addQualifier(const CIMQualifier& x)      Uint32 findQualifier(const String& name) const;
     {  
         _checkRep();  
         _rep->addQualifier(x);  
         return *this;  
     }  
   
     Uint32 findQualifier(const String& name)  
     {  
         _checkRep();  
         return _rep->findQualifier(name);  
     }  
   
     Uint32 findQualifier(const String& name) const  
     {  
         _checkRep();  
         return _rep->findQualifier(name);  
     }  
   
     CIMQualifier getQualifier(Uint32 pos)  
     {  
         _checkRep();  
         return _rep->getQualifier(pos);  
     }  
  
     CIMConstQualifier getQualifier(Uint32 pos) const      CIMQualifier getQualifier(Uint32 pos);
     {  
         _checkRep();  
         return _rep->getQualifier(pos);  
     }  
  
     Uint32 getQualifierCount() const      CIMConstQualifier getQualifier(Uint32 pos) const;
     {  
         _checkRep();  
         return _rep->getQualifierCount();  
     }  
  
     void resolve(DeclContext* declContext, const String& nameSpace)      Uint32 getQualifierCount() const;
     {  
         _checkRep();  
         _rep->resolve(declContext, nameSpace);  
     }  
  
     operator int() const { return _rep != 0; }  #ifdef PEGASUS_INTERNALONLY
       void resolve(DeclContext* declContext, const String& nameSpace);
  
     void toXml(Array<Sint8>& out) const      operator int() const;
     {  #endif
         _checkRep();  
         _rep->toXml(out);  
     }  
  
     void toMof(Array<Sint8>& out) const      void toXml(Array<Sint8>& out) const;
     {  
         _checkRep();  
         _rep->toMof(out);  
     }  
  
       void toMof(Array<Sint8>& out) const;
  
     void print(PEGASUS_STD(ostream) &o=PEGASUS_STD(cout)) const      void print(PEGASUS_STD(ostream)& o=PEGASUS_STD(cout)) const;
     {  
         _checkRep();  
         _rep->print(o);  
     }  
  
     Boolean identical(const CIMConstParameter& x) const;     Boolean identical(const CIMConstParameter& x) const;
  
     CIMParameter clone() const      CIMParameter clone() const;
     {  
         return CIMParameter(_rep->clone());  
     }  
  
 private: private:
  
     CIMParameter(CIMParameterRep* rep) : _rep(rep)      CIMParameter(CIMParameterRep* rep);
     {  
     }  
  
     void _checkRep() const      void _checkRep() const;
     {  
         if (!_rep)  
             ThrowUnitializedHandle();  
     }  
  
     CIMParameterRep* _rep;     CIMParameterRep* _rep;
     friend class CIMConstParameter;     friend class CIMConstParameter;
Line 228 
Line 127 
 { {
 public: public:
  
     CIMConstParameter() : _rep(0)      CIMConstParameter();
     {  
   
     }  
   
     CIMConstParameter(const CIMConstParameter& x)  
     {  
         Inc(_rep = x._rep);  
     }  
   
     CIMConstParameter(const CIMParameter& x)  
     {  
         Inc(_rep = x._rep);  
     }  
  
     CIMConstParameter& operator=(const CIMConstParameter& x)      CIMConstParameter(const CIMConstParameter& x);
     {  
         if (x._rep != _rep)  
         {  
             Dec(_rep);  
             Inc(_rep = x._rep);  
         }  
         return *this;  
     }  
  
     CIMConstParameter& operator=(const CIMParameter& x)      CIMConstParameter(const CIMParameter& x);
     {  
         if (x._rep != _rep)  
         {  
             Dec(_rep);  
             Inc(_rep = x._rep);  
         }  
         return *this;  
     }  
  
     // Throws IllegalName if name argument not legal CIM identifier.     // Throws IllegalName if name argument not legal CIM identifier.
   
     CIMConstParameter(     CIMConstParameter(
         const String& name,         const String& name,
         CIMType type,         CIMType type,
         Boolean isArray = false,         Boolean isArray = false,
         Uint32 arraySize = 0,         Uint32 arraySize = 0,
         const String& referenceClassName = String::EMPTY)          const String& referenceClassName = String::EMPTY);
     {  
         _rep = new CIMParameterRep(  
             name, type, isArray, arraySize, referenceClassName);  
     }  
  
     ~CIMConstParameter()      ~CIMConstParameter();
     {  
         Dec(_rep);  
     }  
  
     const String& getName() const      CIMConstParameter& operator=(const CIMConstParameter& x);
     {  
         _checkRep();  
         return _rep->getName();  
     }  
  
     Boolean isArray() const      CIMConstParameter& operator=(const CIMParameter& x);
     {  
         _checkRep();  
         return _rep->isArray();  
     }  
  
     Uint32 getArraySize() const      const String& getName() const;
     {  
         _checkRep();  
         return _rep->getArraySize();  
     }  
  
     const String& getReferenceClassName() const      Boolean isArray() const;
     {  
         _checkRep();  
         return _rep->getReferenceClassName();  
     }  
  
     CIMType getType() const      Uint32 getArraySize() const;
     {  
         _checkRep();  
         return _rep->getType();  
     }  
  
     Uint32 findQualifier(const String& name) const      const String& getReferenceClassName() const;
     {  
         _checkRep();  
         return _rep->findQualifier(name);  
     }  
  
     CIMConstQualifier getQualifier(Uint32 pos) const      CIMType getType() const;
     {  
         _checkRep();  
         return _rep->getQualifier(pos);  
     }  
  
     Uint32 getQualifierCount() const      Uint32 findQualifier(const String& name) const;
     {  
         _checkRep();  
         return _rep->getQualifierCount();  
     }  
  
     operator int() const { return _rep != 0; }      CIMConstQualifier getQualifier(Uint32 pos) const;
  
     void toXml(Array<Sint8>& out) const      Uint32 getQualifierCount() const;
     {  
         _checkRep();  
         _rep->toXml(out);  
     }  
  
     void print(PEGASUS_STD(ostream) &o=PEGASUS_STD(cout)) const  #ifdef PEGASUS_INTERNALONLY
     {      operator int() const;
         _checkRep();  
         _rep->print(o);  
     }  
  
     Boolean identical(const CIMConstParameter& x) const      void toXml(Array<Sint8>& out) const;
     {  
         x._checkRep();  
         _checkRep();  
         return _rep->identical(x._rep);  
     }  
  
     CIMParameter clone() const      void print(PEGASUS_STD(ostream) &o=PEGASUS_STD(cout)) const;
     {  #endif
         return CIMParameter(_rep->clone());  
     }      Boolean identical(const CIMConstParameter& x) const;
   
       CIMParameter clone() const;
  
 private: private:
  
     void _checkRep() const      void _checkRep() const;
     {  
         if (!_rep)  
             ThrowUnitializedHandle();  
     }  
  
     CIMParameterRep* _rep;     CIMParameterRep* _rep;
     friend class CIMParameter;     friend class CIMParameter;


Legend:
Removed from v.1.15  
changed lines
  Added in v.1.16

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2