1 a.arora 1.3 //%2004////////////////////////////////////////////////////////////////////////
2 //
3 // Copyright (c) 2000, 2001, 2002 BMC Software, Hewlett-Packard Development
4 // Company, L. P., IBM Corp., The Open Group, Tivoli Systems.
5 // Copyright (c) 2003 BMC Software; Hewlett-Packard Development Company, L. P.;
6 // IBM Corp.; EMC Corporation, The Open Group.
7 //
8 // Permission is hereby granted, free of charge, to any person obtaining a copy
9 // of this software and associated documentation files (the "Software"), to
10 // deal in the Software without restriction, including without limitation the
11 // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
12 // sell copies of the Software, and to permit persons to whom the Software is
13 // furnished to do so, subject to the following conditions:
14 //
15 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
16 // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
17 // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
18 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
19 // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
20 // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
21 // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22 a.arora 1.3 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23 //
24 //==============================================================================
25 //
26 // Author: Mike Brasher (mbrasher@bmc.com)
27 // Marek Szermutzky (MSzermutzky@de.ibm.com) PEP#139 Stage2
28 //
29 // Modified By: Nitin Upasani, Hewlett-Packard Company (Nitin_Upasani@hp.com)
30 // Yi Zhou, Hewlett-Packard Company (yi_zhou@hp.com)
31 // Nag Boranna, Hewlett-Packard Company (nagaraja_boranna@hp.com)
32 // Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com)
33 // Carol Ann Krug Graves, Hewlett-Packard Company
34 // (carolann_graves@hp.com)
35 // Jair Santos, Hewlett-Packard Company (jair.santos@hp.com)
36 //%/////////////////////////////////////////////////////////////////////////////
37 #ifndef Pegasus_CIMManagedClient_h
38 #define Pegasus_CIMManagedClient_h
39
40 #include "CIMClientConnectionManager.h"
41
42 // #define CDEBUG(X) PEGASUS_STD(cout) << "CIMManagedClient:" << X << PEGASUS_STD(endl)
43 a.arora 1.3 #define CDEBUG(X);
44
45 PEGASUS_NAMESPACE_BEGIN
46
47 class PEGASUS_CLIENT_LINKAGE CIMManagedClient
48 {
49
50 public:
51
52 // class constructor
53 CIMManagedClient();
54
55 CIMManagedClient(CIMClientConnectionManager* cccm);
56
57 void setConnectionManager(CIMClientConnectionManager* cccm);
58 CIMClientConnectionManager* getConnectionManager(void);
59
60 // virtual class destructor has to be implemented by specific implementation
61 ~CIMManagedClient();
62
63 #ifdef PEGASUS_USE_EXPERIMENTAL_INTERFACES
64 a.arora 1.3 // l10n start
65 /** Sets the accept languages that will be used on the next request.
66 Accept languages are the preferred languages that are to be
67 returned on the response to the next request.
68 @param host - input parameter, string containing hostname of CIMOM
69 @param port - input parameter, string containing port of CIMOM
70 @param langs - REVIEWERS: Complete this
71 */
72 void setRequestAcceptLanguages(const String& host, const String& port, AcceptLanguages& langs);
73
74 /** Gets the accept languages that will be used on the next request.
75 Accept languages are the preferred languages that are to be
76 returned on the response to the next request.
77 @param host - input parameter, string containing hostname of CIMOM
78 @param port - input parameter, string containing port of CIMOM
79 */
80 AcceptLanguages getRequestAcceptLanguages(const String& host, const String& port) const;
81
82 /** Sets the content languages that will be used on the next request.
83 These content languages are the languages of the CIM objects that will
84 sent on the next request.
85 a.arora 1.3 @param host - input parameter, string containing hostname of CIMOM
86 @param port - input parameter, string containing port of CIMOM
87 @param langs REVIEWERS: Complete this
88 */
89 void setRequestContentLanguages(const String& host, const String& port, ContentLanguages& langs);
90
91 /** Gets the content languages that will be used on the next request.
92 * These content languages are the languages of the CIM objects that will
93 * sent on the next request.
94 @param host - input parameter, string containing hostname of CIMOM
95 @param port - input parameter, string containing port of CIMOM
96 */
97 ContentLanguages getRequestContentLanguages(const String& host, const String& port) const;
98
99 /** Gets the content languages of the last response.
100 * These content languages are the languages of the CIM objects, or
101 * CIM exceptions, that were returned on the last response..
102 @param host - input parameter, string containing hostname of CIMOM
103 @param port - input parameter, string containing port of CIMOM
104 */
105 ContentLanguages getResponseContentLanguages(const String& host, const String& port) const;
106 a.arora 1.3
107 /** REVIEWERS: COmplete this
108 *
109 @param host - input parameter, string containing hostname of CIMOM
110 @param port - input parameter, string containing port of CIMOM
111 */
112 void setRequestDefaultLanguages(const String& host, const String& port);
113 // l10n end
114 #endif // PEGASUS_USE_EXPERIMENTAL_INTERFACES
115
116
117 /** The <TT>enumerateInstanceNames</TT> operation enumerates the
118 names (model paths) of the instances of a CIM Class in the target Namespace.
119
120 @param host - input parameter, string containing hostname of CIMOM
121
122 @param port - input parameter, string containing port of CIMOM
123
124 @param nameSpace The nameSpace parameter is a string that defines the target
125 namespace. See defintion of
126 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
127 a.arora 1.3
128 @param className The <TT>className</TT> input parameter defines the Class
129 that is the basis for the enumeration.
130
131 @return If successful, the method returns zero or more names of Instances
132 (model paths) that meet the requested criteria.
133
134 If unsuccessful, one of the following status codes MUST be returned by this
135 method, where the first applicable error in the list (starting with the
136 first element of the list, and working down) is the error returned. Any
137 additional method-specific interpretation of the error in is given in
138 parentheses.
139
140 <UL>
141 <LI>CIM_ERR_ACCESS_DENIED
142 <LI>CIM_ERR_NOT_SUPPORTED
143 <LI>CIM_ERR_INVALID_NAMESPACE
144 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
145 duplicate, unrecognized or otherwise incorrect parameters)
146 <LI>CIM_ERR_INVALID_CLASS (the CIM Class that is the
147 basis for this enumeration does not exist)
148 a.arora 1.3 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
149 </UL>
150 */
151 Array<CIMObjectPath> enumerateInstanceNames(
152 const String& host,
153 const String& port,
154 const CIMNamespaceName& nameSpace,
155 const CIMName& className
156 );
157
158 /** The <TT>enumerateInstances</TT> method enumerates instances of a CIM
159 Class in the target Namespace.
160
161 @param host - input parameter, string containing hostname of CIMOM
162
163 @param port - input parameter, string containing port of CIMOM
164
165 @param nameSpace The nameSpace parameter is a string that defines the target
166 namespace. See defintion of
167 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
168
169 a.arora 1.3 @param className The <TT>className</TT> input parameter defines the
170 Class that is the basis for the enumeration.
171
172 @param localOnly If the <TT>localOnly</TT> input parameter is
173 <TT>true</TT>, this specifies that, for each returned Instance,
174 only elements (properties and qualifiers) overriden within the
175 definition of that Instance are included. If <TT>false</TT>,
176 all elements are returned. This parameter therefore effects a CIM
177 Server-side mechanism to filter certain elements of the returned object
178 based on whether or not they have been propagated from the parent
179 Class (as defined by the <TT>PROPAGATED</TT> attribute).
180
181 Only elements (properties, methods and qualifiers) defined or
182 overridden within the class are included in the response. Propagated
183 properties are not included because their values are based on another class’
184 information. If not specified, all elements of the class’ definition are
185 returned. Note: When instances are returned, the InstanceName must include
186 all keys, including propagated keys. Therefore, these attributes are
187 included in the name part of the method response, but not in the value
188 information.
189
190 a.arora 1.3 @param deepInheritance If the <TT>deepInheritance</TT> input
191 parameter is <TT>true</TT>, this specifies that, for each
192 returned Instance of the Class, all properties of the Instance MUST
193 be present (subject to constraints imposed by the other
194 parameters), including any which were added by subclassing the specified
195 Class. If <TT>false</TT>, each returned Instance includes only
196 properties defined for the specified Class.
197
198 The Enumerate Instances operation returns the same number of instances
199 regardless of whether or not the DeepInheritance flag is set. The
200 DeepInheritance flag is only used to determine whether or not the subclass
201 property values should be returned.
202
203 @param includeQualifiersIf the <TT>includeQualifiers</TT> input
204 parameter is <TT>true</TT>, this specifies that all Qualifiers
205 for each Instance (including Qualifiers on the Instance
206 and on any returned Properties) MUST be included as
207 <TT><QUALIFIER></TT> elements in the response. If false no
208 <TT><QUALIFIER></TT> elements are present in each
209 returned Instance.
210
211 a.arora 1.3 @param includeClassOrigin If the <TT>includeClassOrigin</TT> input
212 parameter is <TT>true</TT>, this specifies that the
213 <TT>CLASSORIGIN</TT> attribute MUST be present on all appropriate
214 elements in each returned Instance. If false, no
215 <TT>CLASSORIGIN</TT> attributes are present in each returned
216 Instance.
217
218 @param propertyList If the <TT>propertyList</TT> input parameter is not
219 <TT>NULL</TT>, the members of the array define one or more CIMProperty
220 names. Each returned Instance MUST NOT include elements
221 for any Properties missing from this list. Note that if
222 <TT>LocalOnly</TT> is specified as <TT>true</TT> (or
223 <TT>DeepInheritance</TT> is specified as <TT>false</TT>) this acts as an
224 additional filter on the set of Properties returned (for example,
225 if CIMProperty <TT>A</TT> is included in the
226 <TT>PropertyList</TT> but <TT>LocalOnly</TT> is set to true and
227 <TT>A</TT> is not local to a returned Instance, then it will not be
228 included in that Instance). If the <TT>PropertyList</TT> input parameter
229 is an empty array this signifies that no Properties are included in each
230 returned Instance. If the <TT>PropertyList</TT> input parameter is
231 NULL this specifies that all Properties (subject to the conditions
232 a.arora 1.3 expressed by the other parameters) are included in each returned
233 Instance.
234
235 If the <TT>propertyList</TT> contains duplicate elements,
236 the Server MUST ignore the duplicates but otherwise process the request
237 normally. If the <TT>PropertyList</TT> contains elements which are
238 invalid CIMProperty names for any target Instance, the Server MUST
239 ignore such entries but otherwise process the request normally.
240
241 @return If successful, the method returns zero or more named
242 Instances that meet the required criteria.
243
244 If unsuccessful, one of the following status codes MUST be returned
245 by this method, where the first applicable error in the list (starting
246 with the first element of the list, and working down) is the error
247 returned. Any additional method-specific interpretation of the error in
248 is given in parentheses.
249
250 <UL>
251 <LI>CIM_ERR_ACCESS_DENIED
252 <LI>CIM_ERR_NOT_SUPPORTED
253 a.arora 1.3 <LI>CIM_ERR_INVALID_NAMESPACE
254 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
255 duplicate, unrecognized or otherwise incorrect parameters)
256 <LI>CIM_ERR_INVALID_CLASS (the CIM Class that is the
257 basis for this enumeration does not exist)
258 <LI>CIM_ERR_FAILED (some other unspecified erroroccurred)</LI>
259 </UL>
260 */
261 Array<CIMInstance> enumerateInstances(
262 const String& host,
263 const String& port,
264 const CIMNamespaceName& nameSpace,
265 const CIMName& className,
266 Boolean deepInheritance = true,
267 Boolean localOnly = true,
268 Boolean includeQualifiers = false,
269 Boolean includeClassOrigin = false,
270 const CIMPropertyList& propertyList = CIMPropertyList()
271 );
272
273 /** The <TT>enumerateClasses</TT> method is used to enumerate subclasses of
274 a.arora 1.3 a CIM Class in the target Namespace.
275
276 @param host - input parameter, string containing hostname of CIMOM
277
278 @param port - input parameter, string containing port of CIMOM
279
280 @param nameSpace The nameSpace parameter is a string that defines the target
281 namespace. See defintion of
282 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
283
284 @param className The <TT>className</TT> input parameter defines the Class
285 that is the basis for the enumeration.
286
287 @param deepInheritance If the <TT>deepInheritance</TT> input
288 parameter is <TT>true</TT>, this specifies that all subclasses of
289 the specified Class should be returned (if the <TT>ClassName</TT> input
290 parameter is absent, this implies that all Classes in the target Namespace
291 should be returned). If <TT>false</TT>, only immediate child
292 subclasses are returned (if the <TT>ClassName</TT> input parameter is
293 NULL, this implies that all base Classes in the target Namespace should be
294 returned).
295 a.arora 1.3
296 @param localOnly If the <TT>localOnly</TT> input parameter is
297 <TT>true</TT>, it specifies that, for each returned Class, only elements
298 (properties, methods and qualifiers) overriden within the definition of
299 that Class are included. If <TT>false</TT>, all elements are
300 returned. This parameter therefore effects a CIM Server-side mechanism
301 to filter certain elements of the returned object based on whether or not
302 they have been propagated from the parent Class (as defined by the
303 <TT>PROPAGATED</TT> attribute).
304
305 @param includeQualifiers If the <TT>includeQualifiers</TT> input parameter
306 is <TT>true</TT>, this specifies that all Qualifiers for each Class
307 (including Qualifiers on the Class and on any returned Properties, Methods
308 or CIMMethod Parameters) MUST be included as <TT><QUALIFIER></TT>
309 elements in the response. If false no <TT><QUALIFIER></TT> elements
310 are present in each returned Class.
311
312 @param includeClassOrigin If the <TT>IncludeClassOrigin</TT> input
313 parameter is <TT>true</TT>, this specifies that the <TT>CLASSORIGIN</TT>
314 attribute MUST be present on all appropriate elements in each returned
315 Class. If false, no <TT>CLASSORIGIN</TT> attributes are present in each
316 a.arora 1.3 returned Class.
317
318 @return If successful, the method returns zero or more Classes that meet the
319 required criteria.
320
321 If unsuccessful, one of the following status codes MUST be returned by
322 this method, where the first applicable error in the list (starting with the
323 first element of the list, and working down) is the error returned. Any
324 additional method-specific interpretation of the error in is given in
325 parentheses.
326
327 <UL>
328 <LI>CIM_ERR_ACCESS_DENIED
329 <LI>CIM_ERR_NOT_SUPPORTED
330 <LI>CIM_ERR_INVALID_NAMESPACE
331 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
332 duplicate, unrecognized or otherwise incorrect parameters)
333 <LI>CIM_ERR_INVALID_CLASS (the CIM Class that is the
334 basis for this enumeration does not exist)
335 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
336 </LI>
337 a.arora 1.3 </UL>
338 */
339 Array<CIMClass> enumerateClasses(
340 const String& host,
341 const String& port,
342 const CIMNamespaceName& nameSpace,
343 const CIMName& className = CIMName(),
344 Boolean deepInheritance = false,
345 Boolean localOnly = true,
346 Boolean includeQualifiers = true,
347 Boolean includeClassOrigin = false
348 );
349 /** The <TT>enumerateClassNames</TT> operation is used to enumerate the
350 names of subclasses of a CIM Class in the target Namespace.
351
352 @param host - input parameter, string containing hostname of CIMOM
353
354 @param port - input parameter, string containing port of CIMOM
355
356 @param nameSpace The nameSpace parameter is a string that defines the target
357 namespace. See defintion of
358 a.arora 1.3 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
359
360 @param className The <TT>className</TT> input parameter defines the Class
361 that is the basis for the enumeration.
362
363 @param deepInheritance If the <TT>deepInheritance</TT> input parameter is
364 true, this specifies that the names of all subclasses of the specified Class
365 should be returned (if the ClassName input parameter is absent, this implies
366 that the names of all Classes in the target Namespace should be returned).
367 If false, only the names of immediate child subclasses are returned (if the
368 className input parameter is NULL, this implies that the names of all base
369 Classes in the target Namespace should be returned). @return If successful,
370 the method returns zero or more names of Classes that meet the requested
371 criteria. If unsuccessful, one of the following status codes MUST be
372 returned by this method, where the first applicable error in the list
373 (starting with the first element of the list, and working down) is the error
374 returned. Any additional method-specific interpretation of the error in is
375 given in parentheses.
376
377 <UL>
378 <LI>CIM_ERR_ACCESS_DENIED
379 a.arora 1.3 <LI>CIM_ERR_NOT_SUPPORTED
380 <LI>CIM_ERR_INVALID_NAMESPACE
381 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
382 duplicate, unrecognized or otherwise incorrect parameters)
383 <LI>CIM_ERR_INVALID_CLASS (the CIM Class that is the
384 basis for this enumeration does not exist)
385 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
386 </UL>
387 */
388 Array<CIMName> enumerateClassNames(
389 const String& host,
390 const String& port,
391 const CIMNamespaceName& nameSpace,
392 const CIMName& className = CIMName(),
393 Boolean deepInheritance = false
394 );
395
396 /** The <TT>getClass</TT> method executes a CIM operation that returns
397 a single CIM Class from the target Namespace where the ClassName input
398 parameter defines the name of the class to be retrieved.
399
400 a.arora 1.3 @param host - input parameter, string containing hostname of CIMOM
401
402 @param port - input parameter, string containing port of CIMOM
403
404 @param nameSpace (Required) The <TT>nameSpace</TT> parameter is a CIMName
405 object that defines the target Namespace. See definition of
406 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
407
408 @param className (Required)The <TT>className</TT> input parameter is a CIMName
409 object that defines the name of the Class to be retrieved.
410
411 @param localOnly (Boolean, Optional, default = true, Input) If the <TT>localOnly</TT> input
412 parameter is true, this specifies that only CIM Elements (properties,
413 methods and qualifiers) overridden within the definition of the Class are
414 returned. If false, all elements are returned. This parameter therefore
415 effects a CIM Server-side mechanism to filter certain elements of the
416 returned object based on whether or not they have been propagated from the
417 parent Class (as defined by the PROPAGATED attribute).
418
419 @param includeQualifiers (Boolean, Optional, default = true, Input) If the
420 <TT>includeQualifiers</TT> input parameter is true, this specifies that
421 a.arora 1.3 all Qualifiers for that Class (including Qualifiers on the Class and on
422 any returned Properties, Methods or CIMMethod Parameters) MUST be included
423 as elements in the response. If false no QUALIFIER elements are present
424 in the returned Class object.
425
426 @param includeClassOrigin (Boolean,Optional, default = false, Input) If
427 the <TT>includeClassOrigin</TT> input parameter is true, this specifies
428 that the CLASSORIGIN attribute MUST be present on all appropriate elements
429 in the returned Class. If false, no CLASSORIGIN attributes are present in
430 the returned Class.
431
432 @param propertyList (optional, Input) If the <TT>propertyList</TT>
433 CIMPropertyList input parameter is not NULL, the members of the array
434 define one or more CIMProperty names. The returned Class WILL NOT include
435 elements for any Properties missing from this list. Note that if
436 LocalOnly is specified as true this acts as an additional filter on the
437 set of Properties returned (for example, if CIMProperty A is included in
438 the PropertyList but LocalOnly is set to true and A is not local to the
439 requested Class, then it will not be included in the response). If the
440 PropertyList input parameter is an empty array this signifies that no
441 Properties are included in the response. If the PropertyList input
442 a.arora 1.3 parameter is NULL this specifies that all Properties (subject to the
443 conditions expressed by the other parameters) are included in the
444 response.
445 @see CIMPropertyList
446
447 If the <TT>propertyList</TT> contains duplicate elements, the Server
448 MUST ignore the duplicates but otherwise process the request normally.
449 If the PropertyList contains elements which are invalid CIMProperty
450 names for the target Class, the Server MUST ignore such entries but
451 otherwise process the request normally.
452
453 @return If successful, the return value is a single CIMClass objcet.
454
455 If unsuccessful, an exception is executed. If the error is local, this may
456 be any local exception.
457 If the error is in the host normally a CIMException is returned with one of the
458 following CIMException codes, where the first applicable error in the list (starting with
459 the first element of the list, and working down) is the error returned.
460 Any additional method-specific interpretation of the error is given
461 in parentheses.
462 <UL>
463 a.arora 1.3 <LI>CIM_ERR_ACCESS_DENIED
464 <LI>CIM_ERR_INVALID_NAMESPACE
465 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
466 duplicate,unrecognized or otherwise incorrect parameters)
467 <LI>CIM_ERR_NOT_FOUND (the request CIM Class does not exist in
468 the specified namespace)
469 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
470 @exceptions REVIEWERS: Need to complete this definition
471 </UL>
472 <pre>
473 ... Connect sequence.
474 CIMNamespace("root/cimv2);
475 Boolean localOnly = true;
476 Boolean includQualifiers = true;
477 Boolean includeClassOrigin = false;
478 CIMPropertyList propertyList; // empty property list
479 try
480 CIMException checkClassException;
481 {
482 CIMClass cimClass = client.getClass(nameSpace,
483 className,
484 a.arora 1.3 localOnly,
485 includeQualifiers,
486 includeClassOrigin,
487 propertyList);
488 }
489 catch(CIMException& e)
490 {
491 if (checkClassException.getCode() = CIM_ERR_NOT_FOUND)
492 cout << "Class " << className << " not found." << endl;
493 ...
494 }
495 catch(Exception& e)
496 {
497 }
498 ...
499
500 // An alternate call with the default parameters would be:
501 // This uses the defaults localOnly = includeQualifiers = true
502 // includeClassOrigin = false. propertyList = Null;
503
504 CIMClass cimClass = client.getClass(nameSpace, className);
505 a.arora 1.3 </pre>
506 @exception REVIEWERS: Complete this
507 @see CIMExcetpion
508 */
509 CIMClass getClass(
510 const String& host,
511 const String& port,
512 const CIMNamespaceName& nameSpace,
513 const CIMName& className,
514 Boolean localOnly = true,
515 Boolean includeQualifiers = true,
516 Boolean includeClassOrigin = false,
517 const CIMPropertyList& propertyList = CIMPropertyList()
518 );
519
520 /** The <TT>createClass</TT> method creates a single CIM Class in
521 the target Namespace. The Class MUST NOT already exist. The NewClass input
522 parameter defines the new Class. The proposed definition MUST be a correct
523 Class definition according to the CIM specification.
524
525 In processing the creation of the new Class, the following rules MUST be
526 a.arora 1.3 conformed to by the CIM Server:
527
528 Any CLASSORIGIN and PROPAGATED attributes in the NewClass MUST be ignored by
529 the Server. If the new Class has no Superclass, the NewClass parameter
530 defines a new base Class. The Server MUST ensure that all Properties and
531 Methods of the new Class have a CLASSORIGIN attribute whose value is the
532 name of the new Class. If the new Class has a Superclass, the NewClass
533 parameter defines a new Subclass of that Superclass. The Superclass MUST
534 exist. The Server MUST ensure that:
535
536 <UL>
537 <LI>Any Properties, Methods or Qualifiers in the Subclass not defined in
538 the Superclass are created as new elements of the Subclass. In
539 particular the Server MUST set the CLASSORIGIN attribute on the new
540 Properties and Methods to the name of the Subclass, and ensure that all
541 other Properties and Methods preserve their CLASSORIGIN attribute value
542 from that defined in the Superclass
543
544 If a CIMProperty is defined in the Superclass and in the Subclass, the
545 value assigned to that property in the Subclass (including NULL) becomes
546 the default value of the property for the Subclass. If a CIMProperty or
547 a.arora 1.3 CIMMethod of the Superclass is not specified in the Subclass, then that
548 CIMProperty or CIMMethod is inherited without modification by the
549 Subclass
550
551 <LI>Any Qualifiers defined in the Superclass with a TOSUBCLASS attribute
552 value of true MUST appear in the resulting Subclass. Qualifiers in the
553 Superclass with a TOSUBCLASS attribute value of false MUST NOT be
554 propagated to the Subclass . Any CIMQualifier propagated from the
555 Superclass cannot be modified in the Subclass if the OVERRIDABLE
556 attribute of that CIMQualifier was set to false in the Superclass. It is
557 a
558 Client error to specify such a CIMQualifier in the NewClass with a
559 different definition to that in the Superclass (where definition
560 encompasses the name, type and flavor attribute settings of the
561 <QUALIFIER> element, and the value of the CIMQualifier).
562 </LI>
563 </UL>
564
565 @param host - input parameter, string containing hostname of CIMOM
566
567 @param port - input parameter, string containing port of CIMOM
568 a.arora 1.3
569 @param nameSpace The nameSpace parameter is a string that defines the target
570 namespace. See defintion of
571 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
572
573 @param newClass The <TT>newClass<?TT> input parameter defines the new Class.
574
575 @return If successful, the specified Class MUST have been created by the CIM
576 Server.
577
578 If unsuccessful, one of the following status codes MUST be returned by this
579 method, where the first applicable error in the list (starting with the
580 first element of the list, and working down) is the error returned. Any
581 additional method-specific interpretation of the error in is given in
582 parentheses.
583 <UL>
584 <LI>CIM_ERR_ACCESS_DENIED
585 <LI>CIM_ERR_NOT_SUPPORTED
586 <LI>CIM_ERR_INVALID_NAMESPACE
587 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
588 unrecognized or otherwise incorrect parameters)
589 a.arora 1.3 <LI>CIM_ERR_ALREADY_EXISTS (the CIM Class already exists)
590 <LI>CIM_ERR_INVALID_SUPERCLASS (the putative CIM Class declares a
591 non-existent superclass)
592 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
593 </UL>
594 */
595 void createClass(
596 const String& host,
597 const String& port,
598 const CIMNamespaceName& nameSpace,
599 const CIMClass& newClass
600 );
601
602 /** The <TT>DeleteClass</TT> method deletes a single CIM Class from the
603 target Namespace.
604
605 @param host - input parameter, string containing hostname of CIMOM
606
607 @param port - input parameter, string containing port of CIMOM
608
609 @param nameSpace The nameSpace parameter is a CIMName that defines
610 a.arora 1.3 the target namespace. See defintion of
611 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
612
613 @param className The <TT>className</TT> input parameter defines the name
614 of the Class to be deleted.
615
616 @return If successful, the specified Class (including any subclasses
617 and any instances) MUST have been removed by the CIM Server. The
618 operation MUST fail if any one of these objects cannot be deleted.
619
620 If unsuccessful, one of the following status codes MUST be returned by
621 this method, where the first applicable error in the list (starting
622 with the first element of the list, and working down) is the error
623 returned. Any additional method-specific interpretation of the error
624 in is given in parentheses.
625
626 <UL>
627 <LI>CIM_ERR_ACCESS_DENIED
628 <LI>CIM_ERR_NOT_SUPPORTED
629 <LI>CIM_ERR_INVALID_NAMESPACE
630 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
631 a.arora 1.3 unrecognized or otherwise incorrect parameters)
632 <LI>CIM_ERR_NOT_FOUND (the CIM Class to be deleted does not exist)
633 <LI>CIM_ERR_CLASS_HAS_CHILDREN (the CIM Class has one or more
634 subclasses which cannot be deleted)
635 <LI>CIM_ERR_CLASS_HAS_INSTANCES (the CIM Class has one or more
636 instances which cannot be deleted)
637 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
638 </UL>
639 */
640 void deleteClass(
641 const String& host,
642 const String& port,
643 const CIMNamespaceName& nameSpace,
644 const CIMName& className
645 );
646 /** The <TT>deleteQualifier</TT> operation deletes a single CIMQualifier
647 declaration from the target Namespace.
648
649 @param host - input parameter, string containing hostname of CIMOM
650
651 @param port - input parameter, string containing port of CIMOM
652 a.arora 1.3
653 @param nameSpace The nameSpace parameter is a CIMName that defines the target
654 namespace. See defintion of
655 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
656
657 @param qualifierName CIMName <TT>qualifierName</TT> input parameter identifies
658 the CIMQualifier whose declaration to be deleted.
659
660 @return If successful, the specified CIMQualifier declaration MUST have been deleted
661 from the Namespace with a normal return from the call.
662
663 If there is any error one of the CIMException errors is returned. The
664 errors are based on the CIM error codes defined below:
665 <UL>
666 <LI>CIM_ERR_ACCESS_DENIED
667 <LI>CIM_ERR_NOT_SUPPORTED
668 <LI>CIM_ERR_INVALID_NAMESPACE
669 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate, unrecognized or
670 otherwise incorrect parameters)
671 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
672 </UL>
673 a.arora 1.3 @exception CIMexception - May return any of the CIMException codes defined above.
674 @exception Exception
675 <pre>
676 // simple function to delete qualifier named "Expensive". Exceptions ignored.
677 CIMClient client;
678 client.connect("localhost", 5988, String::EMPTY, String::EMPTY);
679 CIMName qualifierName("Expensive");
680 client.deleteQualifier(CIMName("root/cimv2",qualifierName);
681 </pre>
682 */
683 void deleteQualifier(
684 const String& host,
685 const String& port,
686 const CIMNamespaceName& nameSpace,
687 const CIMName& qualifierName
688 );
689
690 /** The <TT>getQualifier</TT> operation retrieves a single CIMQualifier
691 declaration from the target Namespace.
692
693 @param host - input parameter, string containing hostname of CIMOM
694 a.arora 1.3
695 @param port - input parameter, string containing port of CIMOM
696
697 @param nameSpace The nameSpace parameter is a CIMNameSpace object that defines
698 the target namespace. See defintion of
699 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
700
701 @param qualifierName The <TT>qualifierName</TT> input parameter is a CIMName object
702 that identifies the CIMQualifier whose declaration to be retrieved.
703
704 @return If successful, the method returns the CIMQualifier declaration for
705 the named CIMQualifier.
706
707 If unsuccessful, one of the following status codes MUST be returned by this
708 method, where the first applicable error in the list (starting with the
709 first element of the list, and working down) is the error returned. Any
710 additional method-specific interpretation of the error in is given in
711 parentheses.
712
713 <UL>
714 <LI>CIM_ERR_ACCESS_DENIED
715 a.arora 1.3 <LI>CIM_ERR_NOT_SUPPORTED
716 <LI>CIM_ERR_INVALID_NAMESPACE
717 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
718 duplicate, unrecognized or otherwise incorrect parameters)
719 <LI>CIM_ERR_INVALID_CLASS (the CIM Class does not exist in the specified
720 namespace)
721 <LI>CIM_ERR_NOT_FOUND (the CIM Class does exist, but the requested
722 CIM Instance does not exist in the specified namespace)
723 <LI>CIM_ERR_NO_SUCH_PROPERTY (the CIM Instance does exist, but the
724 requested CIMProperty does not)
725 <LI>CIM_ERR_TYPE_MISMATCH (the supplied value is incompatible with the
726 type of the CIMProperty)
727 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
728 </UL>
729 */
730 CIMQualifierDecl getQualifier(
731 const String& host,
732 const String& port,
733 const CIMNamespaceName& nameSpace,
734 const CIMName& qualifierName
735 );
736 a.arora 1.3
737 /** The <TT>modifyClass</TT> method modifies an existing CIM Class in the
738 target Namespace.
739
740 The Class MUST already exist. The <TT>ModifiedClass</TT>
741 input parameter defines the set of changes (which MUST be correct
742 amendments to the CIM Class as defined by the CIM Specification) to be made
743 to the current class definition.
744
745 In processing the modifcation of the Class, the following rules MUST be
746 conformed to by the CIM Server.
747
748 <UL>
749 <LI>Any <TT>CLASSORIGIN</TT> and <TT>PROPAGATED</TT> attributes in the
750 <TT>ModifiedClass</TT> MUST be ignored by the Server.
751 <LI>If the modified Class has no Superclass,
752 the<TT>ModifiedClass</TT> parameter defines modifications to a base Class.
753 The Server MUST ensure that:
754 <UL>
755 <LI>All Properties and Methods of the modified Class have a
756 <TT>CLASSORIGIN</TT> attribute whose value is the name of this Class.
757 a.arora 1.3 <LI>Any Properties, Methods or Qualifiers in the existing Class
758 definition which do not appear in the <FONT face="Courier
759 New">ModifiedClass</TT> parameter are removed from the resulting
760 modified Class.</LI>
761 </UL>
762 <LI>If the modified Class has a Superclass,the <TT>ModifiedClass</TT>
763 parameter defines modifications to a Subclass of that Superclass. The
764 Superclass MUST exist, and the Client MUST NOT change the name of the
765 Superclass in the modified Subclass. The Server MUST ensure that:
766 <UL>
767 <LI>Any Properties, Methods or Qualifiers in the Subclass not
768 defined in the Superclass are created as elements of the Subclass. In
769 particular the Server MUST set the <TT>CLASSORIGIN</TT> attribute on the
770 new Properties and Methods to the name of the Subclass, and MUST ensure
771 that all other Properties and Methods preserve their
772 <TT>CLASSORIGIN</TT> attribute value from that defined in the
773 Superclass.
774 <LI>Any CIMProperty, CIMMethod or CIMQualifier previously defined in the
775 Subclass
776 but not defined in the Superclass, and which is not present in the
777 <TT>ModifiedClass</TT> parameter, is removed from the Subclass.
778 a.arora 1.3 <LI>If a CIMProperty is specified in the <TT>ModifiedClass</TT>
779 parameter, the value assigned to that property therein (including
780 NULL) becomes the default value of the property for the Subclass.
781 <LI>If a CIMProperty or CIMMethod of the Superclass is not specified in
782 the
783 Subclass, then that CIMProperty or CIMMethod is inherited
784 without modification by the Subclass (so that any previous changes to
785 such an Element in the Subclass are lost).
786 <LI>If a CIMQualifier in the Superclass is not specified in the
787 Subclass, and the CIMQualifier is defined in the Superclass with a
788 <TT>TOSUBCLASS</TT> attribute value of <TT>true</TT>, then the
789 CIMQualifier
790 MUST still be present in the resulting modified Subclass (it is not
791 possible to remove a propagated CIMQualifier from a Subclass).
792 <LI>Any CIMQualifier propagated from the Superclass cannot be
793 modified in the Subclass if the <TT>OVERRIDABLE</TT> attribute of
794 that CIMQualifier was set to <TT>false</TT> in the Superclass. It is a
795 Client error to specify such a CIMQualifier in the
796 <TT>ModifiedClass</TT>
797 with a different definition to that in the Superclass (where definition
798 encompasses the name, type and flavor attribute settings of the
799 a.arora 1.3 <TT><QUALIFIER></TT> element, and the value of the CIMQualifier).
800 <LI>Any Qualifiers defined in the Superclass with a <TT>TOSUBCLASS</TT>
801 attribute value of <TT>false</TT> MUST NOT be propagated to the
802 Subclass.</LI> </UL>
803 </LI></UL>
804
805 @param host - input parameter, string containing hostname of CIMOM
806
807 @param port - input parameter, string containing port of CIMOM
808
809 @param nameSpace The nameSpace parameter is a string that defines the target
810 namespace. See defintion of
811 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
812
813 @param modifiedClass The <TT>modifiedClass</TT>
814 input parameter defines the set of changes (which MUST be correct
815 amendments to the CIM Class as defined by the CIM Specification) to be made
816 to the current class definition.
817
818 @return If successful, the specified Class MUST have been updated by
819 the CIM Server.
820 a.arora 1.3
821 The request to modify the Class MUST fail if the Server cannot update any
822 existing Subclasses or Instances of that Class in a consistent manner.
823
824 @return If unsuccessful, one of the following status codes MUST be
825 returned by this method, where the first applicable error in the list
826 (starting with the first element of the list, and working down) is the
827 error returned. Any additional method-specific interpretation of the error
828 in is given in parentheses.
829
830 <UL>
831 <LI>CIM_ERR_ACCESS_DENIED
832 <LI>CIM_ERR_NOT_SUPPORTED
833 <LI>CIM_ERR_INVALID_NAMESPACE
834 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
835 duplicate, unrecognized or otherwise incorrect parameters)
836 <LI>CIM_ERR_NOT_FOUND (the CIM Class does not
837 exist)
838 <LI>CIM_ERR_INVALID_SUPERCLASS (the putative CIM Class
839 declares a non-existent or incorrect superclass)
840 <LI>CIM_ERR_CLASS_HAS_CHILDREN (the modification could
841 a.arora 1.3 not be performed because it was not possible to update the subclasses of
842 the Class in a consistent fashion)
843 <LI>CIM_ERR_CLASS_HAS_INSTANCES (the modification could
844 not be performed because it was not possible to update
845 the instances of the Class in a consistent fashion)
846 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
847 </LI></UL>
848 */
849 void modifyClass(
850 const String& host,
851 const String& port,
852 const CIMNamespaceName& nameSpace,
853 const CIMClass& modifiedClass
854 );
855
856 /** The <TT>setQualifier</TT> creates or update a single CIMQualifier
857 declaration in the target Namespace. If the CIMQualifier declaration
858 already exists it is overwritten.
859
860 @param host - input parameter, string containing hostname of CIMOM
861
862 a.arora 1.3 @param port - input parameter, string containing port of CIMOM
863
864 @param nameSpace The nameSpace parameter is a CIMName that defines the target
865 namespace. See defintion of
866 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
867
868 @param CIMQualifierDecl The <TT>CIMQualifierDecl</TT> input parameter is a
869 CIMQualifier object that defines the CIMQualifier Declaration to be added to
870 the Namespace.
871
872 @return If successful, the CIMQualifier declaration MUST have been added to
873 the target Namespace. If a CIMQualifier declaration with the same
874 CIMQualifier name already existed, then it MUST have been replaced by the
875 new declaration.
876
877 If unsuccessful, a CIMException with one of the following status codes MUST be returned
878 by this method, where the first applicable error in the list (starting with
879 the first element of the list, and working down) is the error returned. Any
880 additional method-specific interpretation of the error in is given in
881 parentheses.
882
883 a.arora 1.3 <UL>
884 <LI>CIM_ERR_ACCESS_DENIED
885 <LI>CIM_ERR_NOT_SUPPORTED
886 <LI>CIM_ERR_INVALID_NAMESPACE
887 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
888 duplicate, unrecognized or otherwise incorrect parameters)
889 <LI>CIM_ERR_NOT_FOUND (the requested CIMQualifier declaration did not
890 exist)
891 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
892 </LI>
893 </UL>
894 @exception CIMException - Any of the CIMException codes defined above may
895 be returned.
896 @Exception Exception - TBD
897 <pre>
898 ... Connect with CIMClient object client;
899 CIMNamespaceName nameSpace("root/cimv2");
900 CIMQualifierDecl qual1(
901 CIMName ("CIMTYPE"),
902 String(),
903 CIMScope::PROPERTY,
904 a.arora 1.3 CIMFlavor::TOINSTANCE);
905 try
906 {
907 client.setQualifier(nameSpace, qual1);
908 }
909 catch(CIMException e)
910 {
911 ...
912 }
913 </pre>
914 */
915 void setQualifier(
916 const String& host,
917 const String& port,
918 const CIMNamespaceName& nameSpace,
919 const CIMQualifierDecl& qualifierDeclaration
920 );
921 /** The <TT>enumerateQualifiers</TT> operation is used to enumerate
922 CIMQualifier declarations from the target Namespace.
923
924 @param host - input parameter, string containing hostname of CIMOM
925 a.arora 1.3
926 @param port - input parameter, string containing port of CIMOM
927
928 @param nameSpace The nameSpace parameter is a string that defines the target
929 namespace. See defintion of
930 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
931
932 @return If successful, the method returns zero or more CIMQualifier
933 declarations.
934
935 If unsuccessful, one of the following status codes MUST be returned by this
936 method, where the first applicable error in the list (starting with the
937 first element of the list, and working down) is the error returned. Any
938 additional method-specific interpretation of the error in is given in
939 parentheses.
940
941 <UL>
942 <LI>CIM_ERR_ACCESS_DENIED
943 <LI>CIM_ERR_NOT_SUPPORTED
944 <LI>CIM_ERR_INVALID_NAMESPACE
945 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
946 a.arora 1.3 duplicate, unrecognized or otherwise incorrect parameters)
947 <LI>CIM_ERR_NOT_FOUND (the requested CIMQualifier declaration did not
948 exist)
949 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
950 </LI>
951 </UL>
952 <pre>
953 // function to get all qualifer declarations and print xml form.
954 try
955 {
956 CIMClient client;
957 client.connect("localhost", 5988, String::EMPTY, String::EMPTY);
958 Array<CIMQualifierDecl> qualifierDecls;
959 CIMNamespaceName nameSpace("root/cimv2");
960 qualifierDecls = client.enumerateQualifiers(nameSpace);
961 }
962 catch(Exception& e)
963 {
964 PEGASUS_STD(cerr) << "Error: " << e.getMessage() << PEGASUS_STD(endl);
965 exit(1);
966 }
967 a.arora 1.3 for (Uint32 i = 0; i < qualifierDecls.size(); i++)
968 {
969 XmlWriter::printQualifierDeclElement(qualifierDecls[i], cout);
970 }
971 </pre>
972 */
973 Array<CIMQualifierDecl> enumerateQualifiers(
974 const String& host,
975 const String& port,
976 const CIMNamespaceName& nameSpace
977 );
978
979 /**
980 The <TT>getProperty</TT>operation is used to retrieve a single property
981 value from a CIM Instance in the target Namespace.
982
983 @param instanceName The <TT>instanceName</TT> input parameter specifies the
984 name of the Instance (model path) from which the CIMProperty value is
985 requested. \\Ref{INSTANCENAME}
986 It is a full specified object path, thus it consists also of target namespace,
987 hostname and port
988 a.arora 1.3
989 @param propertyName The <TT>propertyName</TT> input parameter specifies the
990 name of the CIMProperty whose value is to be returned.
991
992 @return If successful, the return value specifies the value of the requested
993 CIMProperty. If the value is NULL then no element is returned.
994
995 If unsuccessful, one of the following status codes MUST be returned by this
996 method, where the first applicable error in the list (starting with the
997 first element of the list, and working down) is the error returned. Any
998 additional method-specific interpretation of the error in is given in
999 parentheses.
1000 <UL>
1001 <LI>CIM_ERR_ACCESS_DENIED
1002 <LI>CIM_ERR_INVALID_NAMESPACE
1003 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
1004 unrecognized or otherwise incorrect parameters)
1005 <LI>CIM_ERR_INVALID_CLASS (the CIM Class does not exist in the specified
1006 namespace)
1007 <LI>CIM_ERR_NOT_FOUND (the CIM Class does exist, but the requested CIM
1008 Instance does not exist in the specified namespace)
1009 a.arora 1.3 <LI><LI>CIM_ERR_NO_SUCH_PROPERTY (the CIM Instance does exist, but the
1010 requested CIMProperty does not)
1011 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
1012 </UL>
1013 */
1014 CIMValue getProperty(
1015 const CIMObjectPath& instanceName,
1016 const CIMName& propertyName
1017 );
1018
1019 /** The <TT>setProperty</TT> operation sets a single property value in a CIM
1020 Instance in the target Namespace.
1021
1022 @param instanceName The <TT>instanceName</TT> input parameter specifies the
1023 name of the Instance (model path) for which the CIMProperty value is to be
1024 updated.
1025 It consists of a full specified object path, thus it consists also of target namespace,
1026 hostname and port
1027
1028 @param propertyName The <TT>propertyName</TT> input parameter specifies the
1029 name of the CIMProperty whose value is to be updated.
1030 a.arora 1.3
1031 @param newValue The NewValue input parameter specifies the new value for the
1032 CIMProperty (which may be NULL).
1033
1034 @return If unsuccessful, one of the following status codes MUST be returned
1035 by this method, where the first applicable error in the list (starting with
1036 the first element of the list, and working down) is the error returned. Any
1037 additional method-specific interpretation of the error in is given in
1038 parentheses.
1039 <UL>
1040 <LI>CIM_ERR_ACCESS_DENIED
1041 <LI>CIM_ERR_INVALID_NAMESPACE
1042
1043 <LI>CIM_ERR_INVALID_PARAMETER (including
1044 missing,duplicate, unrecognized or otherwise incorrect parameters)
1045
1046 <LI>CIM_ERR_INVALID_CLASS (the CIM Class does not exist in the specified
1047 namespace)
1048 <LI>CIM_ERR_NOT_FOUND (the CIM Class does exist, but the requested
1049 CIM Instance does not exist in the specified namespace)
1050 <LI>CIM_ERR_NO_SUCH_PROPERTY (the CIM Instance does exist, but the
1051 a.arora 1.3 requested CIMProperty does not)
1052 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
1053 </UL>
1054 */
1055 void setProperty(
1056 const CIMObjectPath& instanceName,
1057 const CIMName& propertyName,
1058 const CIMValue& newValue = CIMValue()
1059 );
1060
1061 /** The <TT>DeleteInstance</TT> operation deletes a single CIM Instance
1062 from the target Namespace.
1063
1064 @param instanceName The <TT>instanceName</TT> input parameter defines
1065 the name (model path) of the Instance to be deleted.
1066 It is a full specified object path, thus it consists also of target namespace,
1067 hostname and port
1068
1069 @return If successful, the specified Instance MUST have been removed
1070 by the CIM Server.
1071
1072 a.arora 1.3 If unsuccessful, one of the following status codes MUST be returned by
1073 this method, where the first applicable error in the list (starting
1074 with the first element of the list, and working down) is the error
1075 returned. Any additional method-specific interpretation of the error in
1076 is given in parentheses.
1077
1078 <UL>
1079 <LI>CIM_ERR_ACCESS_DENIED
1080 <LI>CIM_ERR_NOT_SUPPORTED
1081 <LI>CIM_ERR_INVALID_NAMESPACE
1082 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
1083 unrecognized or otherwise incorrect parameters)
1084 <LI>CIM_ERR_INVALID_CLASS (the CIM Class does not exist in the
1085 specified namespace)
1086 <LI>CIM_ERR_NOT_FOUND (the CIM Class does exist, but the requested
1087 CIM Instance does not exist in the specified namespace)
1088 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
1089 </UL>
1090 */
1091 void deleteInstance(
1092 const CIMObjectPath& instanceName
1093 a.arora 1.3 );
1094 /** The <TT>createInstance</TT> method creates a single CIM
1095 Instance in the target Namespace. The Instance MUST NOT already exist.
1096
1097 In processing the creation of the new Instance, the following rules MUST be
1098 conformed to by the CIM Server:
1099
1100 Any CLASSORIGIN and PROPAGATED attributes in the NewInstance MUST be ignored
1101 by the Server.
1102
1103 The Server MUST ensure that:
1104
1105 <UL>
1106 <LI>Any Qualifiers in the Instance not defined in the Class are created
1107 as new elements of the Instance.
1108 <LI>All Properties of the Instance preserve their CLASSORIGIN attribute
1109 value from that defined in the Class.
1110 <LI>If a CIMProperty is specified in the ModifiedInstance parameter, the
1111 value assigned to that property in the Instance (including NULL) becomes
1112 the value of the property for the Instance. Note that it is a Client
1113 error to specify a CIMProperty that does not belong to the Class.
1114 a.arora 1.3 <LI>If a CIMProperty of the Class is not specified in the Instance, then
1115 that CIMProperty is inherited without modification by the Instance.
1116 <LI>Any Qualifiers defined in the Class with a TOINSTANCE attribute
1117 value of true appear in the Instance. Qualifiers in the
1118 Class with a TOINSTANCE attribute value of false MUST NOT be propagated
1119 to the Instance.
1120 <LI>Any CIMQualifier propagated from the Class cannot be modified in the
1121 Instance if the OVERRIDABLE attribute of that CIMQualifier was set to
1122 false
1123 in the Class. It is a Client error to specify such a CIMQualifier in the
1124 NewInstance with a different definition to that in the Class (where
1125 definition encompasses the name, type and flavor attribute settings of
1126 the <QUALIFIER> element, and the value of the CIMQualifier).
1127 </UL>
1128
1129 @param newInstance The <TT>newInstance</TT> input parameter defines the new
1130 Instance. The proposed definition MUST be a correct Instance definition for
1131 the underlying CIM Class according to the CIM specification.
1132 It consists of a full specified object path, thus it consists also of target namespace,
1133 hostname and port
1134
1135 a.arora 1.3 @return If successful, the return value defines the object path of the new
1136 CIM Instance relative to the target Namespace (i.e. the Model Path as
1137 defined by the CIM specification), created by the CIM Server. It is
1138 returned in case one or more of the new keys of the Instance are allocated
1139 dynamically during the creation process rather than specified in the
1140 request.
1141
1142 If unsuccessful, one of the following status codes MUST be returned by this
1143 method, where the first applicable error in the list (starting with the
1144 first element of the list, and working down) is the error returned. Any
1145 additional method-specific interpretation of the error in is given in
1146 parentheses.
1147
1148 <UL>
1149 <LI>CIM_ERR_ACCESS_DENIED
1150 <LI>CIM_ERR_NOT_SUPPORTED
1151 <LI>CIM_ERR_INVALID_NAMESPACE
1152 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
1153 unrecognized or otherwise incorrect parameters)
1154 <LI>CIM_ERR_INVALID_CLASS (the CIM Class of which this is to be a new
1155 Instance does not exist)
1156 a.arora 1.3 <LI>CIM_ERR_ALREADY_EXISTS (the CIM Instance already exists)
1157 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
1158 </UL>
1159 */
1160 CIMObjectPath createInstance(
1161 const CIMInstance& newInstance
1162 );
1163
1164 /** Gets the CIM instance for the specified CIM object path.
1165
1166 @param instanceName CIMobjectpath that identifies this CIM instance.
1167 This must include all of the keys.
1168 It is a full specified object path, thus it consists also of target namespace,
1169 hostname and port
1170
1171 @param localOnly If true, only properties and qualifiers overridden
1172 or defined in the returned Instance are included in the response.
1173 If false, all elements of the returned Instance are returned.
1174
1175 @param includeQualifiers If true, all Qualifiers for each Object
1176 (including Qualifiers on the Object and on any returned Properties)
1177 a.arora 1.3 MUST be included. If false no Qualifiers are present in the returned Object.
1178
1179 @param includeClassOrigin If true, CLASSORIGIN attribute MUST be
1180 present on all appropriate elements in each returned Object. If false,
1181 no CLASSORIGIN attributes are present in each returned Object. The CLASSORIGIN
1182 attribute is defined in the DMTF's Specification for the Representation of CIM
1183 in XML. CLASSORIGIN is an XML tag identifying the following text as a class name.
1184 It is attached to a property or method (when specified in XML), to indicate the
1185 class where that property or method is first defined. Where the same property
1186 name is locally defined in another superclass or subclass, the Server will
1187 return the value for the property in the lowest subclass.
1188
1189 @param propertyList If the PropertyList input parameter is not NULL, the
1190 members of the array define one or more Property names. Each returned Object
1191 MUST NOT include elements for any Properties missing from this list.
1192 Note that if LocalOnly is specified as true this acts as an additional
1193 filter on the set of Properties returned (for example, if Property A is
1194 included in the PropertyList but LocalOnly is set to true and A is not local
1195 to a returned Instance, then it will not be included in that Instance).
1196 If the PropertyList input parameter is an empty array this signifies that
1197 no Properties are included in each returned Object. If the PropertyList
1198 a.arora 1.3 input parameter is NULL this specifies that all Properties (subject to
1199 the conditions expressed by the other parameters) are included in each
1200 returned Object. If the PropertyList contains duplicate elements, the
1201 Server ignores the duplicates but otherwise process the request normally.
1202 If the PropertyList contains elements which are invalid Property names for
1203 any target Object, the Server ignores such entries but otherwise process
1204 the request normally.
1205
1206 @return If successful, the CIM instance identified by the CIMObjectPath. If
1207 unsuccessful, an exception is executed.
1208 REVIEWERS: COmplete this.
1209 */
1210
1211 CIMInstance getInstance(
1212 const CIMObjectPath& instanceName,
1213 Boolean localOnly = true,
1214 Boolean includeQualifiers = false,
1215 Boolean includeClassOrigin = false,
1216 const CIMPropertyList& propertyList = CIMPropertyList()
1217 );
1218
1219 a.arora 1.3 /** The <TT>modifyInstance</TT> method modifies an existing CIM
1220 Instance in the target Namespace.
1221
1222 @param modifiedInstance The <TT>modifiedInstance</TT> input parameter
1223 identifies the name of the Instance to be modified, and defines the set of
1224 changes (which MUST be correct amendments to the Instance as
1225 defined by the CIM Specification) to be made to the current Instance
1226 definition.
1227 It consists of a full specified object path, thus it consists also of target namespace,
1228 hostname and port
1229
1230 In processing the modifcation of the Instance, the following rules MUST
1231 be conformed to by the CIM Server:
1232
1233 <UL>
1234 <LI>Any <TT>CLASSORIGIN</TT> and <TT>PROPAGATED</TT> attributes in the
1235 <TT>ModifiedInstance</TT> MUST be ignored by the Server.
1236 <LI>The Class MUST exist, and the Client MUST NOT change
1237 the name of the Class in the modified Instance. The Server MUST ensure
1238 that:
1239 <UL>
1240 a.arora 1.3 <LI>Any Qualifiers in the Instance not defined in
1241 the Class are created as new elements of the Instance.
1242 <LI>All Properties of the Instance preserve their
1243 <TT>CLASSORIGIN</TT> attribute value from that defined in the Class.
1244 <LI>Any CIMQualifier previously defined in the Instance but not
1245 defined in the Class, and which is not present in the
1246 <TT>ModifiedInstance</TT> parameter, is removed from the Instance.
1247
1248 <LI>If a CIMProperty is specified in the <TT>ModifiedInstance</TT>
1249 parameter, the value assigned to that property therein
1250 (including NULL) becomes the value of the property for the Instance.
1251 Note that it is a Client error to specify a CIMProperty that does not
1252 belong to the Class.
1253
1254 <LI>If a CIMProperty of the Class is not specified in the Instance,
1255 then that CIMProperty is inherited without modification by the Instance
1256 (so that any previous changes to that CIMProperty in the Instance are
1257 lost).
1258 <LI>Any Qualifiers defined in the Class with a <TT>TOINSTANCE</TT>
1259 attribute value of <TT>true</TT> appear in the Instance (it is not
1260 possible remove a propagated CIMQualifier from an Instance. Qualifiers
1261 a.arora 1.3 in the Class with a <TT>TOINSTANCE</TT> attribute value of <TT>false</TT>
1262 MUST NOT be propagated to the Instance.
1263 <LI>Any CIMQualifier propagated from the Class cannot be modified by the
1264 Server if the <TT>OVERRIDABLE</TT> attribute of that CIMQualifier was
1265 set to <TT>false</TT> in the Class. It is a Client error to specify such
1266 a CIMQualifier in the <TT>ModifiedInstance</TT> with a different
1267 definition to that in the Class (where definition encompasses the name,
1268 type and flavor attribute settings of the
1269 <TT><QUALIFIER></TT> element, and the value of the CIMQualifier).
1270 <LI>Any CIMQualifier propagated from the Class cannot be modified in
1271 the Instance if the <TT>OVERRIDABLE</TT> attribute of that CIMQualifier
1272 was
1273 set to <TT>false</TT> in the Class. It is a Client error to specify such
1274 a CIMQualifier in the <TT>ModifiedInstance</TT> with a different
1275 definition
1276 to that in the Class (where definition encompasses the name, type and
1277 flavor attribute settings of the <TT><QUALIFIER></TT>
1278 element, and the value of the CIMQualifier).</LI>
1279 </UL>
1280 </LI></UL>
1281
1282 a.arora 1.3 @return If successful, the specified Instance MUST have been updated by the
1283 CIM Server.
1284
1285 If unsuccessful, one of the following status codes MUST be returned by
1286 this method, where the first applicable error in the list (starting with the
1287 first element of the list, and working down) is the error returned. Any
1288 additional method-specific interpretation of the error in is given in
1289 parentheses
1290
1291 <UL>
1292 <LI>CIM_ERR_ACCESS_DENIED
1293 <LI>CIM_ERR_NOT_SUPPORTED
1294 <LI>CIM_ERR_INVALID_NAMESPACE
1295 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
1296 duplicate, unrecognized or otherwise incorrect parameters)
1297 <LI>CIM_ERR_INVALID_CLASS (the CIM Class of which this is
1298 to be a new Instance does not exist)
1299 <LI>CIM_ERR_NOT_FOUND (the CIM Instance does not exist)
1300 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI></UL>
1301 */
1302 void modifyInstance(
1303 a.arora 1.3 const CIMInstance& modifiedInstance,
1304 Boolean includeQualifiers = true,
1305 const CIMPropertyList& propertyList = CIMPropertyList()
1306 );
1307
1308
1309 /** Execute an extrinsic CIM method.
1310 Any CIM Server is assumed to support extrinsic methods. Extrinsic methods
1311 are defined by the Schema supported by the Cim Server. If a CIM Server does
1312 not support extrinsic method invocations, it MUST (subject to the
1313 considerations described in the rest of this section) return the error code
1314 CIM_ERR_NOT_SUPPORTED to any request to execute an extrinsic method. This
1315 allows a CIM client to determine that all attempts to execute extrinsic
1316 methods will fail.
1317
1318 @param instanceName The <TT>instanceName</TT> parameter is a CIMReference
1319 that defines the CIM instance for which the method is defined
1320 It consists of a full specified object path, thus it consists also of target namespace,
1321 hostname and port
1322
1323 @param methodName The <TT>methodName</TT> parameter is a String with the
1324 a.arora 1.3 name of the method to be executed.
1325
1326 @param inParameters This parameter defines an array of input parameters for
1327 the method execution
1328
1329 @param outParameters This parameter defines an array of parameters returned
1330 by the executed method
1331
1332 @return If the Cim Server is unable to perform the extrinsic method
1333 invocation, one of the following status codes MUST be returned by the
1334 CimServer, where the first applicable error in the list (starting with the
1335 first element of the list, and working down) is the error returned. Any
1336 additional specific interpretation of the error is given in parentheses.
1337
1338 ATTN: We have not defined the CIMValue returned
1339 <UL>
1340
1341 <LI>CIM_ERR_ACCESS_DENIED
1342 <LI>CIM_ERR_NOT_SUPPORTED (the CimServer does not support extrinsic
1343 method invocations)
1344 <LI>CIM_ERR_INVALID_NAMESPACE
1345 a.arora 1.3 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
1346 unrecognized or otherwise incorrect parameters)
1347 <LI>CIM_ERR_NOT_FOUND (the target CIM Class or instance does not exist
1348 in the specified namespace)
1349 <LI>CIM_ERR_METHOD_NOT_FOUND
1350 <LI>CIM_ERR_METHOD_NOT_AVAILABLE (the CimServer is unable to honor the
1351 invocation request)
1352 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
1353 </UL>
1354
1355 */
1356 CIMValue invokeMethod(
1357 const CIMObjectPath& instanceName,
1358 const CIMName& methodName,
1359 const Array<CIMParamValue>& inParameters,
1360 Array<CIMParamValue>& outParameters
1361 );
1362
1363 /** The <TT>associatorNames</TT> operation enumerates the names of
1364 CIM Objects (Classes or Instances) that are associated to a particular
1365 source CIM Object.
1366 a.arora 1.3
1367 @param objectName The <TT>objectName</TT> input parameter defines the source
1368 CIM Object whose associated names are to be returned. This is either a Class
1369 name or Instance name (model path).
1370 It is a full specified object path, thus it consists also of target namespace,
1371 hostname and port
1372
1373 @param assocClass The <TT>assocClass</TT> input parameter, if not NULL,
1374 MUST be a valid CIM Association Class name. It acts as a filter on the
1375 returned set of names by mandating that each returned name identifies an
1376 Object that MUST be associated to the source Object via an Instance of this
1377 Class or one of its subclasses.
1378
1379 @param resultClass The <TT>resultClass</TT> input parameter, if not NULL,
1380 MUST be a valid CIM Class name. It acts as a filter on the returned set of
1381 names by mandating that each returned name identifies an Object that MUST be
1382 either an Instance of this Class (or one of its subclasses) or be this Class
1383 (or one of its subclasses).
1384
1385 @param role The <TT>role</TT> input parameter, if not NULL, MUST be a valid
1386 CIMProperty name. It acts as a filter on the returned set of names by
1387 a.arora 1.3 mandating that each returned name identifies an Object that MUST be
1388 associated to the source Object via an Association in which the source
1389 Object plays the specified role (i.e. the name of the CIMProperty in the
1390 Association Class that refers to the source Object MUST match the value of
1391 this parameter).
1392
1393 @param resultRole The <TT>resultRole</TT> input parameter, if not
1394 <TT>NULL</TT>, MUST be a valid CIMProperty name. It acts as a filter on the
1395 returned set of names by mandating that each returned name identifies an
1396 Object that MUST be associated to the source Object via an Association in
1397 which the named returned Object plays the specified role (i.e. the name of
1398 the CIMProperty in the Association Class that refers to the returned Object
1399 MUST match the value of this parameter).
1400
1401 @return If successful, the method returns zero or more full CIM Class paths
1402 or Instance paths of Objects meeting the requested criteria. Since it is
1403 possible for CIM Objects from different hosts or namespaces to be
1404 associated, each returned path is an absolute path that includes host and
1405 namespace information.
1406
1407 If unsuccessful, one of the following status codes MUST be returned by this
1408 a.arora 1.3 method, where the first applicable error in the list (starting with the
1409 first element of the list, and working down) is the error returned. Any
1410 additional method-specific interpretation of the error in is given in
1411 parentheses.
1412
1413 <UL>
1414 <LI>CIM_ERR_ACCESS_DENIED
1415 <LI>CIM_ERR_NOT_SUPPORTED
1416 <LI>CIM_ERR_INVALID_NAMESPACE;
1417 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
1418 duplicate, unrecognized or otherwise incorrect parameters)
1419 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
1420 </UL>
1421 */
1422 Array<CIMObjectPath> associatorNames(
1423 const CIMObjectPath& objectName,
1424 const CIMName& assocClass = CIMName(),
1425 const CIMName& resultClass = CIMName(),
1426 const String& role = String::EMPTY,
1427 const String& resultRole = String::EMPTY
1428 );
1429 a.arora 1.3
1430 /** The <TT>Associators</TT> method enumerates CIM Objects
1431 (Classes or Instances) that are associated to a particular source CIM
1432 Object.
1433
1434 @param objectName The <TT>objectName</TT> input parameter defines the source
1435 CIM Object whose associated Objects are to be returned. This may be either
1436 a Class name or Instance name (model path).
1437 It is a full specified object path, thus it consists also of target namespace,
1438 hostname and port
1439
1440 @param assocClass The <TT>assocClass</TT> input parameter, if not NULL, MUST
1441 be a valid CIM Association Class name. It acts as a filter on the returned
1442 set of Objects by mandating that each returned Object MUST be associated to
1443 the source Object via an Instance of this Class or one of its subclasses.
1444
1445 @param resultClass The <TT>resultClass</TT> input parameter, if not NULL,
1446 MUST be a valid CIM Class name. It acts as a filter on the returned set of
1447 Objects by mandating that each returned Object MUST be either an Instance of
1448 this Class (or one of its subclasses) or be this Class (or one of its
1449 subclasses).
1450 a.arora 1.3
1451 @param role The <TT>role</TT> input parameter, if not NULL, MUST be a valid
1452 CIMProperty name. It acts as a filter on the returned set of Objects by
1453 mandating that each returned Object MUST be associated to the source Object
1454 via an Association in which the source Object plays the specified role (i.e.
1455 the name of the CIMProperty in the Association Class that refers to the
1456 source object MUST match the value of this parameter).
1457
1458 @param resultRole The <TT>resultRole</TT> input parameter, if not NULL, MUST
1459 be a valid CIMProperty name. It acts as a filter on the returned set of
1460 Objects by mandating that each returned Object MUST be associated to the
1461 source Object via an Association in which the returned Object plays the
1462 specified role (i.e. the name of the CIMProperty in the Association Class
1463 that refers to the returned Object MUST match the value of this parameter).
1464
1465 @param includeQualifiers If the <TT>includeQualifiers</TT> input parameter
1466 is true, this specifies that all Qualifiers for each Object (including
1467 Qualifiers on the Object and on any returned Properties) MUST be included as
1468 <QUALIFIER> elements in the response. If false no <QUALIFIER> elements are
1469 present in each returned Object.
1470
1471 a.arora 1.3 @param includeClassOrigin If the <TT>includeClassOrigin</TT> input parameter
1472 is true, this specifies that the CLASSORIGIN attribute MUST be present on
1473 all appropriate elements in each returned Object. If false, no CLASSORIGIN
1474 attributes are present in each returned Object.
1475
1476 @param propertyList If the <TT>propertyList</TT> input parameter is not
1477 NULL, the members of the array define one or more CIMProperty names. Each
1478 returned Object MUST NOT include elements for any Properties missing from
1479 this list. Note that if LocalOnly is specified as true (or DeepInheritance
1480 is specified as false) this acts as an additional filter on the set of
1481 Properties returned (for example, if CIMProperty A is included in the
1482 PropertyList but LocalOnly is set to true and A is not local to a returned
1483 Instance, then it will not be included in that Instance). If the
1484 PropertyList input parameter is an empty array this signifies that no
1485 Properties are included in each returned Object. If the PropertyList input
1486 parameter is NULL this specifies that all Properties (subject to the
1487 conditions expressed by the other parameters) are included in each returned
1488 Object.
1489
1490 If the propertyList contains duplicate elements, the Server MUST ignore the
1491 duplicates but otherwise process the request normally. If the PropertyList
1492 a.arora 1.3 contains elements which are invalid CIMProperty names for any target Object,
1493 the Server MUST ignore such entries but otherwise process the request
1494 normally.
1495
1496 Clients SHOULD NOT explicitly specify properties in the PropertyList
1497 parameter unless they have specified a non-NULL value for the ResultClass
1498 parameter.
1499
1500 @return If successful, the method returns zero or more CIM Classes or
1501 Instances meeting the requested criteria. Since it is possible for CIM
1502 Objects from different hosts or namespaces to be associated, each returned
1503 Object includes location information.
1504
1505 If unsuccessful, one of the following status codes MUST be returned by this
1506 method, where the first applicable error in the list (starting with the
1507 first element of the list, and working down) is the error returned. Any
1508 additional method-specific interpretation of the error in is given in
1509 parentheses.
1510
1511 <UL>
1512 <LI>CIM_ERR_ACCESS_DENIED
1513 a.arora 1.3 <LI>CIM_ERR_NOT_SUPPORTED
1514 <LI>CIM_ERR_INVALID_NAMESPACE
1515 <LI>CIM_ERR_INVALID_PARAMETER (including
1516 missing,duplicate, unrecognized or
1517 otherwise incorrect parameters)
1518 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
1519 </UL>
1520 */
1521 Array<CIMObject> associators(
1522 const CIMObjectPath& objectName,
1523 const CIMName& assocClass = CIMName(),
1524 const CIMName& resultClass = CIMName(),
1525 const String& role = String::EMPTY,
1526 const String& resultRole = String::EMPTY,
1527 Boolean includeQualifiers = false,
1528 Boolean includeClassOrigin = false,
1529 const CIMPropertyList& propertyList = CIMPropertyList()
1530 );
1531 /** The <TT>references</TT> operation enumerates the association
1532 objects that refer to a particular target CIM Object (Class or Instance).
1533
1534 a.arora 1.3 @param The NameSpace parameter is a string that defines the target
1535 namespace \Ref{NAMESPACE}
1536
1537 @param objectName The <TT>objectName</TT> input parameter defines the target
1538 CIM Object whose referring Objects are to be returned. This is either a
1539 Class name or Instance name (model path).
1540 It is a full specified object path, thus it consists also of target namespace,
1541 hostname and port
1542
1543 @param resultClass The <TT>resultClass</TT> input parameter, if not NULL,
1544 MUST be a valid CIM Class name. It acts as a filter on the returned set of
1545 Objects by mandating that each returned Object MUST be an Instance of this
1546 Class (or one of its subclasses), or this Class (or one of its subclasses).
1547
1548 @param role The <TT>role</TT> input parameter, if not NULL, MUST be a valid
1549 CIMProperty name. It acts as a filter on the returned set of Objects by
1550 mandating that each returned Objects MUST refer to the target Object via a
1551 CIMProperty whose name matches the value of this parameter.
1552
1553 @param includeQualifiers. If the <TT>includeQualifiers</TT> input parameter
1554 is true, this specifies that all Qualifiers for each Object (including
1555 a.arora 1.3 Qualifiers on the Object and on any returned Properties) MUST be included as
1556 <QUALIFIER> elements in the response. If false no <QUALIFIER> elements are
1557 present in each returned Object.
1558
1559 @param includeClassOrigin If the <TT>includeClassOrigin</TT> input parameter
1560 is true, this specifies that the CLASSORIGIN attribute MUST be present on
1561 all appropriate elements in each returned Object. If false, no CLASSORIGIN
1562 attributes are present in each returned Object.
1563
1564 @param propertyList If the <TT>propertyList</TT> input parameter is not
1565 NULL, the members of the array define one or more CIMProperty names. Each
1566 returned Object MUST NOT include elements for any Properties missing from
1567 this list. Note that if LocalOnly is specified as true (or DeepInheritance
1568 is specified as false) this acts as an additional filter on the set of
1569 Properties returned (for example, if CIMProperty A is included in the
1570 PropertyList but LocalOnly is set to true and A is not local to a returned
1571 Instance, then it will not be included in that Instance). If the
1572 PropertyList input parameter is an empty array this signifies that no
1573 Properties are included in each returned Object. If the PropertyList input
1574 parameter is NULL this specifies that all Properties (subject to the
1575 conditions expressed by the other parameters) are included in each returned
1576 a.arora 1.3 Object.
1577
1578 If the PropertyList contains duplicate elements, the Server MUST ignore the
1579 duplicates but otherwise process the request normally. If the PropertyList
1580 contains elements which are invalid CIMProperty names for any target Object,
1581 the Server MUST ignore such entries but otherwise process the request
1582 normally.
1583
1584 Clients SHOULD NOT explicitly specify properties in the PropertyList
1585 parameter unless they have specified a non-NULL value for the ResultClass
1586 parameter.
1587
1588 @return If successful, the method returns zero or more CIM Classes or
1589 Instances meeting the requested criteria. Since it is possible for CIM
1590 Objects from different hosts or namespaces to be associated, each returned
1591 Object includes location information.
1592
1593 If unsuccessful, one of the following status codes MUST be returned by this
1594 method, where the first applicable error in the list (starting with the
1595 first element of the list, and working down) is the error returned. Any
1596 additional method-specific interpretation of the error in is given in
1597 a.arora 1.3 parentheses.
1598
1599 <UL>
1600 <LI>CIM_ERR_ACCESS_DENIED
1601 <LI>CIM_ERR_NOT_SUPPORTED
1602 <LI>CIM_ERR_INVALID_NAMESPACE
1603 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
1604 duplicate, unrecognized or otherwise incorrect parameters)
1605 <LI>CIM_ERR_FAILED (some other unspecified error occurred)</LI>
1606 </UL>
1607 */
1608 Array<CIMObject> references(
1609 const CIMObjectPath& objectName,
1610 const CIMName& resultClass = CIMName(),
1611 const String& role = String::EMPTY,
1612 Boolean includeQualifiers = false,
1613 Boolean includeClassOrigin = false,
1614 const CIMPropertyList& propertyList = CIMPropertyList()
1615 );
1616
1617 /** The <TT>referenceNames</TT> operation enumerates the association
1618 a.arora 1.3 objects that refer to a particular target CIM Object (Class or Instance).
1619
1620 @param objectName The <TT>objectName</TT> input parameter defines the target
1621 CIM Object whose referring object names are to be returned. It may be either
1622 a Class name or an Instance name (model path).
1623 It consists of a full specified object path, thus it consists also of target namespace,
1624 hostname and port
1625
1626 @param resultClass The <TT>resultClass</TT> input parameter, if not NULL,
1627 MUST be a valid CIM Class name. It acts as a filter on the returned set of
1628 Object Names by mandating that each returned Object CIMName MUST identify an
1629 Instance of this Class (or one of its subclasses), or this Class (or one of
1630 its subclasses).
1631
1632 @param role The <TT>role</TT> input parameter, if not NULL, MUST be a valid
1633 CIMProperty name. It acts as a filter on the returned set of Object Names by
1634 mandating that each returned Object CIMName MUST identify an Object that
1635 refers to the target Instance via a CIMProperty whose name matches the value
1636 of this parameter.
1637
1638 @return If successful,the method returns the names of zero or more full CIM
1639 a.arora 1.3 Class paths or Instance paths of Objects meeting the requested criteria.
1640 Since it is possible for CIM Objects from different hosts or namespaces to
1641 be associated, each returned path is an absolute path that includes host and
1642 namespace information.
1643
1644 If unsuccessful, one of the following status codes MUST be returned by this
1645 method, where the first applicable error in the list (starting with the
1646 first element of the list, and working down) is the error returned. Any
1647 additional method-specific interpretation of the error in is given in
1648 parentheses.
1649 <UL>
1650 <LI>CIM_ERR_ACCESS_DENIED
1651 <LI>CIM_ERR_NOT_SUPPORTED
1652 <LI>CIM_ERR_INVALID_NAMESPACE
1653 <LI>CIM_ERR_INVALID_PARAMETER (including missing, duplicate,
1654 unrecognized or otherwise incorrect parameters)
1655 <LI>CIM_ERR_FAILED (some other unspecified error occurred)
1656 </UL>
1657 */
1658 Array<CIMObjectPath> referenceNames(
1659 const CIMObjectPath& objectName,
1660 a.arora 1.3 const CIMName& resultClass = CIMName(),
1661 const String& role = String::EMPTY
1662 );
1663
1664 /** The <TT>execQuery</TT> is used to execute a query against the target
1665 Namespace.
1666
1667 @param host - input parameter, string containing hostname of CIMOM
1668
1669 @param port - input parameter, string containing port of CIMOM
1670
1671 @param nameSpace The nameSpace parameter is a string that defines the target
1672 namespace. See defintion of
1673 \URL[Namespace]{DefinitionofTerms.html#NAMESPACE}.
1674
1675 @param queryLanguage The <TT>queryLanguage</TT> String input parameter
1676 defines the query language in which the Query parameter is expressed.
1677
1678 @param query The <TT>query</TT> input parameter defines the query to be
1679 executed.
1680
1681 a.arora 1.3 @return If successful, the method returns zero or more CIM Classes or
1682 Instances that correspond to the results set of the query.
1683
1684 If unsuccessful, one of the following status codes MUST be returned by this
1685 method, where the first applicable error in the list (starting with the
1686 first element of the list, and working down) is the error returned. Any
1687 additional method-specific interpretation of the error in is given in
1688 parentheses.
1689
1690 <UL>
1691 <LI>CIM_ERR_ACCESS_DENIED
1692 <LI>CIM_ERR_NOT_SUPPORTED
1693 <LI>CIM_ERR_INVALID_NAMESPACE
1694 <LI>CIM_ERR_INVALID_PARAMETER (including missing,
1695 duplicate, unrecognized or otherwise incorrect parameters)
1696 <LI>CIM_ERR_QUERY_LANGUAGE_NOT_SUPPORTED (the requested query language is
1697 not recognized)
1698 <LI>CIM_ERR_INVALID_QUERY (the query is not a valid query in the
1699 specified query language)
1700 <LI>CIM_ERR_FAILED (some other unspecified error ccurred)</LI>
1701 </UL>
1702 a.arora 1.3 */
1703 Array<CIMObject> execQuery(
1704 const String& host,
1705 const String& port,
1706 const CIMNamespaceName& nameSpace,
1707 const String& queryLanguage,
1708 const String& query
1709 );
1710
1711
1712 private:
1713 void hasHostandNameSpace(const String& _host, const CIMNamespaceName& nameSpace) throw(TypeMismatchException);
1714 void hasHostandNameSpace(const CIMObjectPath& inObjectPath) throw(TypeMismatchException);
1715 void hasHostandNameSpace(const CIMInstance& inInstance) throw(TypeMismatchException);
1716
1717 CIMClientRep* getTargetCIMOM(const String& _host,const String& _port, const CIMNamespaceName& _nameSpace) const;
1718 CIMClientRep* getTargetCIMOM(const CIMObjectPath& inObjectPath) const;
1719
1720 void setPegasusDefaultPort(void);
1721 void checkCompleteObjectPath(const CIMObjectPath& inObjectPath);
1722 String _getHostwithPort(const String& host, const String& port);
1723 a.arora 1.3
1724 CIMClientConnectionManager * _cccm;
1725 String _pegasusDefaultPort;
1726
1727 };
1728
1729 PEGASUS_NAMESPACE_END
1730
1731 #endif // Pegasus_CIMManagedClient_h
|