1 martin 1.4 //%LICENSE////////////////////////////////////////////////////////////////
|
2 martin 1.5 //
|
3 martin 1.4 // Licensed to The Open Group (TOG) under one or more contributor license
4 // agreements. Refer to the OpenPegasusNOTICE.txt file distributed with
5 // this work for additional information regarding copyright ownership.
6 // Each contributor licenses this file to you under the OpenPegasus Open
7 // Source License; you may not use this file except in compliance with the
8 // License.
|
9 martin 1.5 //
|
10 martin 1.4 // Permission is hereby granted, free of charge, to any person obtaining a
11 // copy of this software and associated documentation files (the "Software"),
12 // to deal in the Software without restriction, including without limitation
13 // the rights to use, copy, modify, merge, publish, distribute, sublicense,
14 // and/or sell copies of the Software, and to permit persons to whom the
15 // Software is furnished to do so, subject to the following conditions:
|
16 martin 1.5 //
|
17 martin 1.4 // The above copyright notice and this permission notice shall be included
18 // in all copies or substantial portions of the Software.
|
19 martin 1.5 //
|
20 martin 1.4 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
|
21 martin 1.5 // OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
|
22 martin 1.4 // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
23 // IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
24 // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
25 // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
26 // SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
27 martin 1.5 //
|
28 martin 1.4 //////////////////////////////////////////////////////////////////////////
|
29 kumpf 1.2 //
30 //%/////////////////////////////////////////////////////////////////////////////
31
32 #ifndef Pegasus_WsmResponseEncoder_h
33 #define Pegasus_WsmResponseEncoder_h
34
35 #include <Pegasus/Common/Config.h>
36 #include <Pegasus/WsmServer/WsmResponse.h>
37
38 PEGASUS_NAMESPACE_BEGIN
39
|
40 kumpf 1.3 class WsmResponse;
41 class SoapResponse;
42
|
43 kumpf 1.2 /** This class encodes WS-Man operation requests and passes them up-stream.
44 */
45 class WsmResponseEncoder
46 {
47 public:
48
49 WsmResponseEncoder();
50 ~WsmResponseEncoder();
51
52 void enqueue(WsmResponse* response);
53
|
54 kumpf 1.6 // The encoding of enumeration responses must be separated from the
55 // sending of the responses to allow proper handling of MaxEnvelopeSize.
56 SoapResponse* encodeWsenEnumerateResponse(
57 WsenEnumerateResponse* response,
58 Uint32& numDataItemsEncoded);
59 SoapResponse* encodeWsenPullResponse(
60 WsenPullResponse* response,
61 Uint32& numDataItemsEncoded);
62 void sendResponse(SoapResponse* response)
63 {
64 _sendResponse(response);
65 }
66
|
67 kumpf 1.2 private:
68
|
69 kumpf 1.3 void _sendResponse(SoapResponse* response);
70 void _sendUnreportableSuccess(WsmResponse* response);
|
71 kumpf 1.6 SoapResponse* _buildEncodingLimitFault(WsmResponse* response);
|
72 kumpf 1.3
73 void _encodeWxfGetResponse(WxfGetResponse* response);
74 void _encodeWxfPutResponse(WxfPutResponse* response);
75 void _encodeWxfCreateResponse(WxfCreateResponse* response);
76 void _encodeWxfDeleteResponse(WxfDeleteResponse* response);
77 void _encodeWsenReleaseResponse(WsenReleaseResponse* response);
|
78 kumpf 1.2 void _encodeWsmFaultResponse(WsmFaultResponse* response);
79 void _encodeSoapFaultResponse(SoapFaultResponse* response);
|
80 mike 1.7 void _encodeWsInvokeResponse(WsInvokeResponse* response);
|
81 kumpf 1.3
82 Boolean _encodeEnumerationData(
83 SoapResponse& soapResponse,
84 Buffer& headers,
85 WsmOperationType operation,
86 Uint64 contextId,
87 Boolean isComplete,
|
88 kumpf 1.6 WsenEnumerationData& data,
|
89 mike 1.7 Uint32& numDataItemsEncoded,
90 const String& resourceUri);
|
91 kumpf 1.2 };
92
93 PEGASUS_NAMESPACE_END
94
95 #endif /* Pegasus_WsmResponseEncoder_h */
|