1 karl 1.72 //%2005////////////////////////////////////////////////////////////////////////
|
2 mike 1.21 //
|
3 karl 1.69 // 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 karl 1.64 // IBM Corp.; EMC Corporation, The Open Group.
|
7 karl 1.69 // Copyright (c) 2004 BMC Software; Hewlett-Packard Development Company, L.P.;
8 // IBM Corp.; EMC Corporation; VERITAS Software Corporation; The Open Group.
|
9 karl 1.72 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
10 // EMC Corporation; VERITAS Software Corporation; The Open Group.
|
11 mike 1.21 //
12 // Permission is hereby granted, free of charge, to any person obtaining a copy
|
13 kumpf 1.48 // of this software and associated documentation files (the "Software"), to
14 // deal in the Software without restriction, including without limitation the
15 // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
16 mike 1.21 // sell copies of the Software, and to permit persons to whom the Software is
17 // furnished to do so, subject to the following conditions:
18 //
|
19 kumpf 1.48 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
|
20 mike 1.21 // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
21 // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
|
22 kumpf 1.48 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
23 // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
24 // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
|
25 mike 1.21 // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
26 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
27 //
28 //==============================================================================
29 //
30 // Author: Mike Brasher (mbrasher@bmc.com)
31 //
|
32 mike 1.22 // Modified By:
33 // Nitin Upasani, Hewlett-Packard Company (Nitin_Upasani@hp.com)
34 // Nag Boranna, Hewlett-Packard Company (nagaraja_boranna@hp.com)
35 // Roger Kumpf, Hewlett-Packard Company (roger_kumpf@hp.com)
|
36 kumpf 1.45 // Carol Ann Krug Graves, Hewlett-Packard Company
37 // (carolann_graves@hp.com)
|
38 brian.campbell 1.67 // Brian G. Campbell, EMC (campbell_brian@emc.com) - PEP140/phase1
|
39 w.white 1.68 // Willis White (whiwill@us.ibm.com) PEP 127 and 128
|
40 brian.campbell 1.70 // Brian G. Campbell, EMC (campbell_brian@emc.com) - PEP140/phase2
|
41 david.dillard 1.71 // David Dillard, VERITAS Software Corp. (david.dillard@veritas.com)
|
42 vijay.eli 1.73 // Vijay Eli, vijayeli@in.ibm.com, fix for #2571
|
43 mike 1.21 //
44 //%/////////////////////////////////////////////////////////////////////////////
45
46 #ifndef Pegasus_XmlWriter_h
47 #define Pegasus_XmlWriter_h
48
49 #include <iostream>
50 #include <Pegasus/Common/Config.h>
|
51 kumpf 1.53 #include <Pegasus/Common/InternalException.h>
|
52 kumpf 1.55 #include <Pegasus/Common/ArrayInternal.h>
|
53 mike 1.21 #include <Pegasus/Common/String.h>
54 #include <Pegasus/Common/Indentor.h>
|
55 kumpf 1.41 #include <Pegasus/Common/CIMObject.h>
56 #include <Pegasus/Common/CIMClass.h>
57 #include <Pegasus/Common/CIMInstance.h>
58 #include <Pegasus/Common/CIMProperty.h>
59 #include <Pegasus/Common/CIMMethod.h>
60 #include <Pegasus/Common/CIMParameter.h>
61 #include <Pegasus/Common/CIMQualifier.h>
62 #include <Pegasus/Common/CIMQualifierDecl.h>
63 #include <Pegasus/Common/CIMValue.h>
|
64 kumpf 1.44 #include <Pegasus/Common/CIMObjectPath.h>
|
65 mike 1.22 #include <Pegasus/Common/CIMPropertyList.h>
|
66 kumpf 1.29 #include <Pegasus/Common/CIMParamValue.h>
|
67 kumpf 1.59 #include <Pegasus/Common/Message.h>
|
68 kumpf 1.49 #include <Pegasus/Common/Linkage.h>
|
69 chuck 1.62 #include <Pegasus/Common/ContentLanguages.h> // l10n
70 #include <Pegasus/Common/AcceptLanguages.h> // l10n
|
71 mike 1.75 #include <Pegasus/Common/Buffer.h>
|
72 mike 1.76 #include <Pegasus/Common/StrLit.h>
|
73 mike 1.21
74 PEGASUS_NAMESPACE_BEGIN
75
|
76 chuck 1.62 // l10n - added accept language and content language support below
77
|
78 mike 1.21 class PEGASUS_COMMON_LINKAGE XmlWriter
79 {
80 public:
81
|
82 mike 1.75 static void append(Buffer& out, const Char16& x);
|
83 mike 1.21
|
84 mike 1.75 static void append(Buffer& out, char x)
|
85 mike 1.21 {
|
86 chuck 1.66 out.append(x);
|
87 mike 1.21 }
88
|
89 mike 1.75 static void append(Buffer& out, Boolean x);
|
90 kumpf 1.39
|
91 mike 1.75 static void append(Buffer& out, Uint32 x);
|
92 kumpf 1.26
|
93 mike 1.75 static void append(Buffer& out, Sint32 x);
|
94 kumpf 1.39
|
95 mike 1.75 static void append(Buffer& out, Uint64 x);
|
96 kumpf 1.39
|
97 mike 1.75 static void append(Buffer& out, Sint64 x);
|
98 kumpf 1.39
|
99 mike 1.75 static void append(Buffer& out, Real32 x);
|
100 chuck 1.65
|
101 mike 1.75 static void append(Buffer& out, Real64 x);
|
102 kumpf 1.39
|
103 mike 1.75 static void append(Buffer& out, const char* str);
|
104 mike 1.21
|
105 mike 1.75 static void append(Buffer& out, const String& str);
|
106 mike 1.21
|
107 mike 1.75 static void append(Buffer& out, const Indentor& x);
|
108 mike 1.21
|
109 mike 1.75 static void appendSpecial(Buffer& out, const Char16& x);
|
110 mike 1.21
|
111 mike 1.75 static void appendSpecial(Buffer& out, char x);
|
112 mike 1.21
|
113 mike 1.75 static void appendSpecial(Buffer& out, const char* str);
|
114 mike 1.21
|
115 mike 1.75 static void appendSpecial(Buffer& out, const String& str);
|
116 mike 1.21
|
117 mike 1.75 static String encodeURICharacters(const Buffer& uriString);
|
118 vijay.eli 1.73 static String encodeURICharacters(const String& uriString);
|
119 kumpf 1.60
|
120 kumpf 1.28 static void appendLocalNameSpacePathElement(
|
121 mike 1.75 Buffer& out,
|
122 kumpf 1.58 const CIMNamespaceName& nameSpace);
|
123 mike 1.21
|
124 kumpf 1.28 static void appendNameSpacePathElement(
|
125 mike 1.75 Buffer& out,
|
126 kumpf 1.28 const String& host,
|
127 kumpf 1.58 const CIMNamespaceName& nameSpace);
|
128 mike 1.21
|
129 kumpf 1.28 static void appendClassNameElement(
|
130 mike 1.75 Buffer& out,
|
131 kumpf 1.58 const CIMName& className);
|
132 mike 1.21
|
133 kumpf 1.28 static void appendInstanceNameElement(
|
134 mike 1.75 Buffer& out,
|
135 kumpf 1.44 const CIMObjectPath& instanceName);
|
136 kumpf 1.26
|
137 kumpf 1.28 static void appendClassPathElement(
|
138 mike 1.75 Buffer& out,
|
139 kumpf 1.44 const CIMObjectPath& classPath);
|
140 mike 1.21
|
141 kumpf 1.28 static void appendInstancePathElement(
|
142 mike 1.75 Buffer& out,
|
143 kumpf 1.44 const CIMObjectPath& instancePath);
|
144 mike 1.21
|
145 kumpf 1.28 static void appendLocalClassPathElement(
|
146 mike 1.75 Buffer& out,
|
147 kumpf 1.44 const CIMObjectPath& classPath);
|
148 mike 1.21
|
149 kumpf 1.28 static void appendLocalInstancePathElement(
|
150 mike 1.75 Buffer& out,
|
151 kumpf 1.44 const CIMObjectPath& instancePath);
|
152 mike 1.21
|
153 kumpf 1.29 static void appendLocalObjectPathElement(
|
154 mike 1.75 Buffer& out,
|
155 kumpf 1.44 const CIMObjectPath& objectPath);
|
156 kumpf 1.39
157 static void appendValueElement(
|
158 mike 1.75 Buffer& out,
|
159 kumpf 1.39 const CIMValue& value);
160
161 static void printValueElement(
162 const CIMValue& value,
163 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
|
164 kumpf 1.29
|
165 kumpf 1.41 static void appendValueObjectWithPathElement(
|
166 mike 1.75 Buffer& out,
|
167 kumpf 1.47 const CIMObject& objectWithPath);
|
168 kumpf 1.41
169 static void appendValueReferenceElement(
|
170 mike 1.75 Buffer& out,
|
171 kumpf 1.44 const CIMObjectPath& reference,
|
172 kumpf 1.41 Boolean putValueWrapper);
173
174 static void printValueReferenceElement(
|
175 kumpf 1.44 const CIMObjectPath& reference,
|
176 kumpf 1.41 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
177
178 static void appendValueNamedInstanceElement(
|
179 mike 1.75 Buffer& out,
|
180 kumpf 1.45 const CIMInstance& namedInstance);
|
181 kumpf 1.41
|
182 kumpf 1.40 static void appendClassElement(
|
183 mike 1.75 Buffer& out,
|
184 kumpf 1.40 const CIMConstClass& cimclass);
185
186 static void printClassElement(
187 const CIMConstClass& cimclass,
188 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
189
190 static void appendInstanceElement(
|
191 mike 1.75 Buffer& out,
|
192 kumpf 1.40 const CIMConstInstance& instance);
193
194 static void printInstanceElement(
195 const CIMConstInstance& instance,
|
196 kumpf 1.41 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
197
198 static void appendObjectElement(
|
199 mike 1.75 Buffer& out,
|
200 kumpf 1.41 const CIMConstObject& object);
201
202 static void appendPropertyElement(
|
203 mike 1.75 Buffer& out,
|
204 kumpf 1.41 const CIMConstProperty& property);
205
206 static void printPropertyElement(
207 const CIMConstProperty& property,
208 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
209
210 static void appendMethodElement(
|
211 mike 1.75 Buffer& out,
|
212 kumpf 1.41 const CIMConstMethod& method);
213
214 static void printMethodElement(
215 const CIMConstMethod& method,
216 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
217
218 static void appendParameterElement(
|
219 mike 1.75 Buffer& out,
|
220 kumpf 1.41 const CIMConstParameter& parameter);
221
222 static void printParameterElement(
223 const CIMConstParameter& parameter,
224 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
225
226 static void appendParamValueElement(
|
227 mike 1.75 Buffer& out,
|
228 kumpf 1.41 const CIMParamValue& paramValue);
229
230 static void printParamValueElement(
231 const CIMParamValue& paramValue,
232 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
233
234 static void appendQualifierElement(
|
235 mike 1.75 Buffer& out,
|
236 kumpf 1.41 const CIMConstQualifier& qualifier);
237
238 static void printQualifierElement(
239 const CIMConstQualifier& qualifier,
240 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
241
242 static void appendQualifierDeclElement(
|
243 mike 1.75 Buffer& out,
|
244 kumpf 1.41 const CIMConstQualifierDecl& qualifierDecl);
245
246 static void printQualifierDeclElement(
247 const CIMConstQualifierDecl& qualifierDecl,
|
248 kumpf 1.40 PEGASUS_STD(ostream)& os=PEGASUS_STD(cout));
249
|
250 kumpf 1.42 static void appendQualifierFlavorEntity(
|
251 mike 1.75 Buffer& out,
|
252 kumpf 1.52 const CIMFlavor & flavor);
|
253 kumpf 1.42
|
254 kumpf 1.43 static void appendScopeElement(
|
255 mike 1.75 Buffer& out,
|
256 kumpf 1.51 const CIMScope & scope);
|
257 kumpf 1.43
|
258 kumpf 1.28 static void appendMethodCallHeader(
|
259 mike 1.75 Buffer& out,
|
260 kumpf 1.28 const char* host,
|
261 kumpf 1.58 const CIMName& cimMethod,
|
262 kumpf 1.28 const String& cimObject,
263 const String& authenticationHeader,
|
264 kumpf 1.59 HttpMethod httpMethod,
|
265 chuck 1.62 const AcceptLanguages & acceptLanguages,
266 const ContentLanguages & contentLanguages,
|
267 kumpf 1.28 Uint32 contentLength);
|
268 mike 1.21
|
269 brian.campbell 1.70 // added to accommodate sending WBEMServerResponseTime PEP #128
|
270 w.white 1.68 static void appendMethodResponseHeader(
|
271 mike 1.75 Buffer& out,
|
272 w.white 1.68 HttpMethod httpMethod,
273 const ContentLanguages & contentLanguages,
274 Uint32 contentLength,
|
275 w.white 1.74 Uint32 serverResponseTime = 0);
|
276 w.white 1.68
|
277 kumpf 1.34 static void appendHttpErrorResponseHeader(
|
278 mike 1.75 Buffer& out,
|
279 kumpf 1.34 const String& status,
280 const String& cimError = String::EMPTY,
|
281 kumpf 1.35 const String& errorDetail = String::EMPTY);
|
282 kumpf 1.34
|
283 kumpf 1.28 static void appendUnauthorizedResponseHeader(
|
284 mike 1.75 Buffer& out,
|
285 kumpf 1.28 const String& content);
|
286 mike 1.21
|
287 gerarda 1.63 #ifdef PEGASUS_KERBEROS_AUTHENTICATION
288 static void appendOKResponseHeader(
|
289 mike 1.75 Buffer& out,
|
290 gerarda 1.63 const String& content);
291 #endif
292
|
293 kumpf 1.26 static void appendReturnValueElement(
|
294 mike 1.75 Buffer& out,
|
295 kumpf 1.26 const CIMValue& value);
296
297 static void appendBooleanIParameter(
|
298 mike 1.75 Buffer& out,
|
299 kumpf 1.26 const char* name,
|
300 mike 1.21 Boolean flag);
301
|
302 kumpf 1.26 static void appendStringIParameter(
|
303 mike 1.75 Buffer& out,
|
304 kumpf 1.26 const char* name,
|
305 mike 1.21 const String& str);
306
|
307 kumpf 1.26 static void appendQualifierNameIParameter(
|
308 mike 1.75 Buffer& out,
|
309 kumpf 1.26 const char* name,
310 const String& qualifierName);
311
312 static void appendClassNameIParameter(
|
313 mike 1.75 Buffer& out,
|
314 kumpf 1.26 const char* name,
|
315 kumpf 1.58 const CIMName& className);
|
316 mike 1.21
|
317 kumpf 1.26 static void appendInstanceNameIParameter(
|
318 mike 1.75 Buffer& out,
|
319 kumpf 1.26 const char* name,
|
320 kumpf 1.44 const CIMObjectPath& instanceName);
|
321 mike 1.21
|
322 kumpf 1.26 static void appendObjectNameIParameter(
|
323 mike 1.75 Buffer& out,
|
324 kumpf 1.26 const char* name,
|
325 kumpf 1.44 const CIMObjectPath& objectName);
|
326 mike 1.21
|
327 kumpf 1.26 static void appendClassIParameter(
|
328 mike 1.75 Buffer& out,
|
329 kumpf 1.26 const char* name,
330 const CIMConstClass& cimClass);
|
331 mike 1.21
|
332 kumpf 1.26 static void appendInstanceIParameter(
|
333 mike 1.75 Buffer& out,
|
334 kumpf 1.26 const char* name,
|
335 mike 1.21 const CIMConstInstance& instance);
336
|
337 kumpf 1.26 static void appendNamedInstanceIParameter(
|
338 mike 1.75 Buffer& out,
|
339 kumpf 1.26 const char* name,
|
340 mday 1.46 const CIMInstance& namedInstance) ;
|
341 mike 1.22
|
342 kumpf 1.26 static void appendPropertyNameIParameter(
|
343 mike 1.75 Buffer& out,
|
344 kumpf 1.58 const CIMName& propertyName);
|
345 mike 1.21
|
346 kumpf 1.26 static void appendPropertyValueIParameter(
|
347 mike 1.75 Buffer& out,
|
348 kumpf 1.26 const char* name,
349 const CIMValue& value);
|
350 mike 1.21
|
351 kumpf 1.26 static void appendPropertyListIParameter(
|
352 mike 1.75 Buffer& out,
|
353 kumpf 1.26 const CIMPropertyList& propertyList);
|
354 mike 1.21
|
355 kumpf 1.26 static void appendQualifierDeclarationIParameter(
|
356 mike 1.75 Buffer& out,
|
357 kumpf 1.26 const char* name,
358 const CIMConstQualifierDecl& qualifierDecl);
|
359 kumpf 1.34
|
360 mike 1.75 static Buffer formatHttpErrorRspMessage(
|
361 kumpf 1.34 const String& status,
362 const String& cimError = String::EMPTY,
|
363 kumpf 1.35 const String& errorDetail = String::EMPTY);
|
364 mike 1.21
|
365 mike 1.75 static Buffer formatSimpleMethodReqMessage(
|
366 kumpf 1.26 const char* host,
|
367 kumpf 1.58 const CIMNamespaceName& nameSpace,
|
368 kumpf 1.44 const CIMObjectPath& path,
|
369 kumpf 1.58 const CIMName& methodName,
|
370 kumpf 1.29 const Array<CIMParamValue>& parameters,
|
371 kumpf 1.26 const String& messageId,
|
372 kumpf 1.59 HttpMethod httpMethod,
|
373 chuck 1.62 const String& authenticationHeader,
374 const AcceptLanguages& httpAcceptLanguages,
375 const ContentLanguages& httpContentLanguages);
|
376 mike 1.21
|
377 w.white 1.68 //PEP 128 - sending serverResponseTime (WBEMServerResponseTime) in respons header
|
378 mike 1.75 static Buffer formatSimpleMethodRspMessage(
|
379 w.white 1.68 const CIMName& methodName,
380 const String& messageId,
381 HttpMethod httpMethod,
382 const ContentLanguages & httpContentLanguages,
|
383 mike 1.75 const Buffer& body,
|
384 w.white 1.74 Uint32 serverResponseTime,
|
385 w.white 1.68 Boolean isFirst = true,
386 Boolean isLast = true);
|
387 mike 1.21
|
388 mike 1.75 static Buffer formatSimpleMethodErrorRspMessage(
|
389 kumpf 1.58 const CIMName& methodName,
|
390 kumpf 1.27 const String& messageId,
|
391 kumpf 1.59 HttpMethod httpMethod,
|
392 kumpf 1.36 const CIMException& cimException);
|
393 kumpf 1.27
|
394 mike 1.75 static Buffer formatSimpleIMethodReqMessage(
|
395 mike 1.21 const char* host,
|
396 kumpf 1.58 const CIMNamespaceName& nameSpace,
397 const CIMName& iMethodName,
|
398 mike 1.22 const String& messageId,
|
399 kumpf 1.59 HttpMethod httpMethod,
|
400 mike 1.22 const String& authenticationHeader,
|
401 chuck 1.62 const AcceptLanguages& httpAcceptLanguages,
402 const ContentLanguages& httpContentLanguages,
|
403 mike 1.75 const Buffer& body);
|
404 mike 1.21
|
405 w.white 1.68 //PEP 128 - sending serverResponseTime (WBEMServerResponseTime) in respons header
|
406 mike 1.75 static Buffer formatSimpleIMethodRspMessage(
|
407 kumpf 1.58 const CIMName& iMethodName,
|
408 mike 1.21 const String& messageId,
|
409 kumpf 1.59 HttpMethod httpMethod,
|
410 chuck 1.62 const ContentLanguages & httpContentLanguages,
|
411 mike 1.75 const Buffer& body,
|
412 w.white 1.74 Uint32 serverResponseTime,
|
413 brian.campbell 1.67 Boolean isFirst = true,
414 Boolean isLast = true);
|
415 mike 1.21
|
416 mike 1.75 static Buffer formatSimpleIMethodErrorRspMessage(
|
417 kumpf 1.58 const CIMName& iMethodName,
|
418 mike 1.22 const String& messageId,
|
419 kumpf 1.59 HttpMethod httpMethod,
|
420 kumpf 1.36 const CIMException& cimException);
|
421 mike 1.22
|
422 kumpf 1.61 static void appendInstanceEParameter(
|
423 mike 1.75 Buffer& out,
|
424 kumpf 1.61 const char* name,
425 const CIMInstance& instance);
426
|
427 kumpf 1.26 static void appendEMethodRequestHeader(
|
428 mike 1.75 Buffer& out,
|
429 kumpf 1.38 const char* requestUri,
|
430 mike 1.22 const char* host,
|
431 kumpf 1.58 const CIMName& cimMethod,
|
432 kumpf 1.59 HttpMethod httpMethod,
|
433 mike 1.22 const String& authenticationHeader,
|
434 chuck 1.62 const AcceptLanguages& acceptLanguages,
435 const ContentLanguages& contentLanguages,
|
436 kumpf 1.26 Uint32 contentLength);
|
437 mike 1.22
|
438 kumpf 1.26 static void appendEMethodResponseHeader(
|
439 mike 1.75 Buffer& out,
|
440 kumpf 1.59 HttpMethod httpMethod,
|
441 chuck 1.62 const ContentLanguages& contentLanguages,
|
442 kumpf 1.26 Uint32 contentLength);
|
443 mike 1.22
|
444 mike 1.75 static Buffer formatSimpleEMethodReqMessage(
|
445 kumpf 1.38 const char* requestUri,
|
446 mike 1.22 const char* host,
|
447 kumpf 1.58 const CIMName& eMethodName,
|
448 mike 1.22 const String& messageId,
|
449 kumpf 1.59 HttpMethod httpMethod,
|
450 kumpf 1.26 const String& authenticationHeader,
|
451 chuck 1.62 const AcceptLanguages& httpAcceptLanguages,
452 const ContentLanguages& httpContentLanguages,
|
453 mike 1.75 const Buffer& body);
|
454 mike 1.22
|
455 mike 1.75 static Buffer formatSimpleEMethodRspMessage(
|
456 kumpf 1.58 const CIMName& eMethodName,
|
457 mike 1.22 const String& messageId,
|
458 kumpf 1.59 HttpMethod httpMethod,
|
459 chuck 1.62 const ContentLanguages& httpContentLanguages,
|
460 mike 1.75 const Buffer& body);
|
461 kumpf 1.27
|
462 mike 1.75 static Buffer formatSimpleEMethodErrorRspMessage(
|
463 kumpf 1.58 const CIMName& eMethodName,
|
464 kumpf 1.27 const String& messageId,
|
465 kumpf 1.59 HttpMethod httpMethod,
|
466 kumpf 1.36 const CIMException& cimException);
|
467 mike 1.22
|
468 kumpf 1.26 static void indentedPrint(
469 PEGASUS_STD(ostream)& os,
470 const char* text,
471 Uint32 indentChars = 2);
|
472 mike 1.22
|
473 kumpf 1.26 static String getNextMessageId();
|
474 mike 1.21
|
475 kumpf 1.57 /** Converts the given CIMKeyBinding type to one of the following:
|
476 kumpf 1.50 "boolean", "string", or "numeric"
477 */
|
478 kumpf 1.57 static const char* keyBindingTypeToString (CIMKeyBinding::Type type);
|
479 kumpf 1.50
|
480 mike 1.21 private:
|
481 kumpf 1.28
482 static void _appendMessageElementBegin(
|
483 mike 1.75 Buffer& out,
|
484 kumpf 1.28 const String& messageId);
485 static void _appendMessageElementEnd(
|
486 mike 1.75 Buffer& out);
|
487 kumpf 1.28
|
488 mike 1.75 static void _appendSimpleReqElementBegin(Buffer& out);
489 static void _appendSimpleReqElementEnd(Buffer& out);
|
490 kumpf 1.28
491 static void _appendMethodCallElementBegin(
|
492 mike 1.75 Buffer& out,
|
493 kumpf 1.58 const CIMName& name);
|
494 kumpf 1.28 static void _appendMethodCallElementEnd(
|
495 mike 1.75 Buffer& out);
|
496 kumpf 1.28
497 static void _appendIMethodCallElementBegin(
|
498 mike 1.75 Buffer& out,
|
499 kumpf 1.58 const CIMName& name);
|
500 kumpf 1.28 static void _appendIMethodCallElementEnd(
|
501 mike 1.75 Buffer& out);
|
502 kumpf 1.28
503 static void _appendIParamValueElementBegin(
|
504 mike 1.75 Buffer& out,
|
505 kumpf 1.28 const char* name);
506 static void _appendIParamValueElementEnd(
|
507 mike 1.75 Buffer& out);
|
508 kumpf 1.28
|
509 mike 1.75 static void _appendSimpleRspElementBegin(Buffer& out);
510 static void _appendSimpleRspElementEnd(Buffer& out);
|
511 kumpf 1.28
512 static void _appendMethodResponseElementBegin(
|
513 mike 1.75 Buffer& out,
|
514 kumpf 1.58 const CIMName& name);
|
515 kumpf 1.28 static void _appendMethodResponseElementEnd(
|
516 mike 1.75 Buffer& out);
|
517 kumpf 1.28
518 static void _appendIMethodResponseElementBegin(
|
519 mike 1.75 Buffer& out,
|
520 kumpf 1.58 const CIMName& name);
|
521 kumpf 1.28 static void _appendIMethodResponseElementEnd(
|
522 mike 1.75 Buffer& out);
|
523 kumpf 1.28
524 static void _appendErrorElement(
|
525 mike 1.75 Buffer& out,
|
526 kumpf 1.36 const CIMException& cimException);
|
527 kumpf 1.28
|
528 mike 1.75 static void _appendIReturnValueElementBegin(Buffer& out);
529 static void _appendIReturnValueElementEnd(Buffer& out);
|
530 kumpf 1.28
|
531 mike 1.75 static void _appendSimpleExportReqElementBegin(Buffer& out);
532 static void _appendSimpleExportReqElementEnd(Buffer& out);
|
533 kumpf 1.28
534 static void _appendEMethodCallElementBegin(
|
535 mike 1.75 Buffer& out,
|
536 kumpf 1.58 const CIMName& name);
|
537 kumpf 1.28 static void _appendEMethodCallElementEnd(
|
538 mike 1.75 Buffer& out);
|
539 kumpf 1.61
540 static void _appendEParamValueElementBegin(
|
541 mike 1.75 Buffer& out,
|
542 kumpf 1.61 const char* name);
543 static void _appendEParamValueElementEnd(
|
544 mike 1.75 Buffer& out);
|
545 kumpf 1.28
|
546 mike 1.75 static void _appendSimpleExportRspElementBegin(Buffer& out);
547 static void _appendSimpleExportRspElementEnd(Buffer& out);
|
548 kumpf 1.28
549 static void _appendEMethodResponseElementBegin(
|
550 mike 1.75 Buffer& out,
|
551 kumpf 1.58 const CIMName& name);
|
552 kumpf 1.28 static void _appendEMethodResponseElementEnd(
|
553 mike 1.75 Buffer& out);
|
554 mike 1.21
555 XmlWriter() { }
556 };
557
|
558 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(
559 Buffer& out,
|
560 mike 1.21 const char* x);
561
|
562 mike 1.76 inline Buffer& operator<<(Buffer& out, char x)
563 {
564 out.append(x);
565 return out;
566 }
567
568 inline Buffer& operator<<(Buffer& out, const char* s)
569 {
570 out.append(s, strlen(s));
571 return out;
572 }
|
573 mike 1.21
|
574 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(Buffer& out, const Char16& x);
|
575 mike 1.21
|
576 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(
577 Buffer& out,
|
578 mike 1.21 const String& x);
579
|
580 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(
581 Buffer& out,
|
582 mike 1.21 const Indentor& x);
583
|
584 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(
585 Buffer& out,
586 const Buffer& x);
|
587 mike 1.21
|
588 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(
589 Buffer& out,
|
590 mike 1.21 Uint32 x);
591
|
592 mike 1.75 PEGASUS_COMMON_LINKAGE Buffer& operator<<(
593 Buffer& out,
|
594 kumpf 1.58 const CIMName& name);
595
|
596 kumpf 1.54 PEGASUS_COMMON_LINKAGE PEGASUS_STD(ostream)& operator<<(
597 PEGASUS_STD(ostream)& os,
598 const CIMDateTime& x);
|
599 kumpf 1.58
600 PEGASUS_COMMON_LINKAGE PEGASUS_STD(ostream)& operator<<(
601 PEGASUS_STD(ostream)& os,
602 const CIMName& name);
603
604 PEGASUS_COMMON_LINKAGE PEGASUS_STD(ostream)& operator<<(
605 PEGASUS_STD(ostream)& os,
606 const CIMNamespaceName& name);
|
607 kumpf 1.54
|
608 mike 1.21 PEGASUS_NAMESPACE_END
609
610 #endif /* Pegasus_XmlWriter_h */
|