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

  1 mike  1.12 //%/////////////////////////////////////////////////////////////////////////////
  2            //
  3 kumpf 1.21 // Copyright (c) 2000, 2001, 2002 BMC Software, Hewlett-Packard Company, IBM,
  4            // The Open Group, Tivoli Systems
  5 mike  1.12 //
  6            // Permission is hereby granted, free of charge, to any person obtaining a copy
  7 kumpf 1.21 // of this software and associated documentation files (the "Software"), to
  8            // deal in the Software without restriction, including without limitation the
  9            // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
 10 mike  1.12 // sell copies of the Software, and to permit persons to whom the Software is
 11            // furnished to do so, subject to the following conditions:
 12            // 
 13 kumpf 1.21 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
 14 mike  1.12 // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
 15            // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
 16 kumpf 1.21 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
 17            // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
 18            // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
 19 mike  1.12 // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
 20            // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 21            //
 22            //==============================================================================
 23            //
 24            // Author: Mike Brasher (mbrasher@bmc.com)
 25            //
 26 kumpf 1.16 // Modified By: Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com)
 27 kumpf 1.22 //              Carol Ann Krug Graves, Hewlett-Packard Company
 28            //                (carolann_graves@hp.com)
 29 mike  1.12 //
 30            //%/////////////////////////////////////////////////////////////////////////////
 31            
 32            #ifndef Pegasus_Parameter_h
 33            #define Pegasus_Parameter_h
 34            
 35            #include <Pegasus/Common/Config.h>
 36 kumpf 1.24 #include <Pegasus/Common/CIMName.h>
 37 kumpf 1.16 #include <Pegasus/Common/CIMQualifier.h>
 38            #include <Pegasus/Common/CIMType.h>
 39 kumpf 1.23 #include <Pegasus/Common/Linkage.h>
 40 mike  1.12 
 41            PEGASUS_NAMESPACE_BEGIN
 42            
 43            ////////////////////////////////////////////////////////////////////////////////
 44            //
 45            // CIMParameter
 46            //
 47            ////////////////////////////////////////////////////////////////////////////////
 48            
 49 kumpf 1.22 class Resolver;
 50 mike  1.12 class CIMConstParameter;
 51 kumpf 1.16 class CIMParameterRep;
 52 mike  1.12 
 53            class PEGASUS_COMMON_LINKAGE CIMParameter
 54            {
 55            public:
 56            
 57 kumpf 1.16     CIMParameter();
 58 mike  1.12 
 59 kumpf 1.16     CIMParameter(const CIMParameter& x);
 60 mike  1.12 
 61                CIMParameter(
 62 kumpf 1.24 	const CIMName& name, 
 63 mike  1.12 	CIMType type,
 64            	Boolean isArray = false,
 65            	Uint32 arraySize = 0,
 66 kumpf 1.24 	const CIMName& referenceClassName = CIMName());
 67 kumpf 1.16 
 68                ~CIMParameter();
 69            
 70                CIMParameter& operator=(const CIMParameter& x);
 71            
 72 kumpf 1.24     const CIMName& getName() const ;
 73 mike  1.12 
 74 kumpf 1.24     void setName(const CIMName& name);
 75 mike  1.12 
 76 kumpf 1.16     Boolean isArray() const;
 77 kumpf 1.15 
 78 kumpf 1.16     Uint32 getArraySize() const;
 79            
 80 kumpf 1.24     const CIMName& getReferenceClassName() const ;
 81 kumpf 1.16 
 82                CIMType getType() const ;
 83            
 84                void setType(const CIMType type);
 85 mike  1.12 
 86 kumpf 1.28     // Throws AlreadyExistsException.
 87 kumpf 1.16     CIMParameter& addQualifier(const CIMQualifier& x);
 88            
 89 kumpf 1.24     Uint32 findQualifier(const CIMName& name) const;
 90 mike  1.12 
 91 kumpf 1.29     CIMQualifier getQualifier(Uint32 index);
 92 kumpf 1.16 
 93 kumpf 1.27     /** removeQualifier - Removes the CIMQualifier defined by the
 94                    specified index
 95            
 96 kumpf 1.29         @param index index of the qualifier to be removed
 97 kumpf 1.27 
 98 kumpf 1.28         @exception IndexOutOfBoundsException if the index is outside
 99                    the range of qualifiers available for the CIMParameter
100 kumpf 1.27     */
101 kumpf 1.29     void removeQualifier (Uint32 index);
102 kumpf 1.27 
103 kumpf 1.29     CIMConstQualifier getQualifier(Uint32 index) const;
104 kumpf 1.16 
105                Uint32 getQualifierCount() const;
106            
107 kumpf 1.26     /**
108                    Determines if the object has not been initialized.
109            
110                    @return  True if the object has not been initialized,
111                             False otherwise
112                 */
113                Boolean isUninitialized() const;
114 kumpf 1.16 
115 mike  1.12     Boolean identical(const CIMConstParameter& x) const;
116            
117 kumpf 1.16     CIMParameter clone() const;
118 mike  1.12 
119            private:
120            
121 kumpf 1.16     CIMParameter(CIMParameterRep* rep);
122            
123                void _checkRep() const;
124 mike  1.12 
125                CIMParameterRep* _rep;
126 kumpf 1.19 
127 mike  1.12     friend class CIMConstParameter;
128 kumpf 1.22     friend class Resolver;
129 kumpf 1.18     friend class XmlWriter;
130 kumpf 1.19     friend class MofWriter;
131 mike  1.12 };
132            
133            ////////////////////////////////////////////////////////////////////////////////
134            //
135            // CIMConstParameter
136            //
137            ////////////////////////////////////////////////////////////////////////////////
138            
139            class PEGASUS_COMMON_LINKAGE CIMConstParameter
140            {
141            public:
142            
143 kumpf 1.16     CIMConstParameter();
144 mike  1.12 
145 kumpf 1.16     CIMConstParameter(const CIMConstParameter& x);
146 mike  1.12 
147 kumpf 1.16     CIMConstParameter(const CIMParameter& x);
148 mike  1.12 
149                CIMConstParameter(
150 kumpf 1.24 	const CIMName& name, 
151 mike  1.12 	CIMType type,
152            	Boolean isArray = false,
153            	Uint32 arraySize = 0,
154 kumpf 1.24 	const CIMName& referenceClassName = CIMName());
155 kumpf 1.16 
156                ~CIMConstParameter();
157            
158                CIMConstParameter& operator=(const CIMConstParameter& x);
159            
160                CIMConstParameter& operator=(const CIMParameter& x);
161            
162 kumpf 1.24     const CIMName& getName() const;
163 kumpf 1.16 
164                Boolean isArray() const;
165            
166                Uint32 getArraySize() const;
167            
168 kumpf 1.24     const CIMName& getReferenceClassName() const;
169 kumpf 1.16 
170                CIMType getType() const;
171            
172 kumpf 1.24     Uint32 findQualifier(const CIMName& name) const;
173 kumpf 1.16 
174 kumpf 1.29     CIMConstQualifier getQualifier(Uint32 index) const;
175 kumpf 1.16 
176                Uint32 getQualifierCount() const;
177            
178 kumpf 1.26     Boolean isUninitialized() const;
179 kumpf 1.16 
180                Boolean identical(const CIMConstParameter& x) const;
181            
182                CIMParameter clone() const;
183 mike  1.12 
184            private:
185            
186 kumpf 1.16     void _checkRep() const;
187 mike  1.12 
188                CIMParameterRep* _rep;
189                friend class CIMParameter;
190 kumpf 1.18     friend class XmlWriter;
191 kumpf 1.19     friend class MofWriter;
192 mike  1.12 };
193            
194            #define PEGASUS_ARRAY_T CIMParameter
195 kumpf 1.20 # include <Pegasus/Common/ArrayInter.h>
196 mike  1.12 #undef PEGASUS_ARRAY_T
197            
198            PEGASUS_NAMESPACE_END
199            
200            #endif /* Pegasus_Parameter_h */

No CVS admin address has been configured
Powered by
ViewCVS 0.9.2