1 karl 1.26 //%2006////////////////////////////////////////////////////////////////////////
|
2 mike 1.2 //
|
3 karl 1.20 // 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.19 // IBM Corp.; EMC Corporation, The Open Group.
|
7 karl 1.20 // 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.22 // Copyright (c) 2005 Hewlett-Packard Development Company, L.P.; IBM Corp.;
10 // EMC Corporation; VERITAS Software Corporation; The Open Group.
|
11 karl 1.26 // Copyright (c) 2006 Hewlett-Packard Development Company, L.P.; IBM Corp.;
12 // EMC Corporation; Symantec Corporation; The Open Group.
|
13 mike 1.2 //
14 // Permission is hereby granted, free of charge, to any person obtaining a copy
|
15 kumpf 1.16 // of this software and associated documentation files (the "Software"), to
16 // deal in the Software without restriction, including without limitation the
17 // rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
|
18 mike 1.2 // sell copies of the Software, and to permit persons to whom the Software is
19 // furnished to do so, subject to the following conditions:
20 //
|
21 kumpf 1.16 // THE ABOVE COPYRIGHT NOTICE AND THIS PERMISSION NOTICE SHALL BE INCLUDED IN
|
22 mike 1.2 // ALL COPIES OR SUBSTANTIAL PORTIONS OF THE SOFTWARE. THE SOFTWARE IS PROVIDED
23 // "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT
|
24 kumpf 1.16 // LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
25 // PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
26 // HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
|
27 mike 1.2 // ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
28 // WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
29 //
30 //==============================================================================
31 //
32 //%/////////////////////////////////////////////////////////////////////////////
33
34 #ifndef Pegasus_CIMExportRequestDecoder_h
35 #define Pegasus_CIMExportRequestDecoder_h
36
37 #include <Pegasus/Common/Config.h>
|
38 mday 1.4 #include <Pegasus/Common/MessageQueueService.h>
|
39 mike 1.2 #include <Pegasus/Common/CIMMessage.h>
40 #include <Pegasus/Common/HTTPMessage.h>
41 #include <Pegasus/ExportServer/Linkage.h>
|
42 kumpf 1.25 #include <Pegasus/Common/AcceptLanguageList.h>
43 #include <Pegasus/Common/ContentLanguageList.h>
|
44 mike 1.2
45 PEGASUS_NAMESPACE_BEGIN
46
47 class XmlParser;
48
49 /** This class decodes CIM operation requests and passes them down-stream.
|
50 mday 1.5 */
|
51 mike 1.2 class PEGASUS_EXPORT_SERVER_LINKAGE CIMExportRequestDecoder
|
52 mday 1.15 : public MessageQueueService
|
53 mike 1.2 {
|
54 mday 1.5 public:
|
55 mike 1.2
|
56 mday 1.15 typedef MessageQueueService Base;
|
57 mday 1.3
|
58 mday 1.5 CIMExportRequestDecoder(
|
59 mday 1.6 MessageQueueService* outputQueue,
|
60 mday 1.5 Uint32 returnQueueId);
|
61 mike 1.2
|
62 mday 1.5 ~CIMExportRequestDecoder();
|
63 mike 1.2
|
64 mday 1.5 void sendResponse(
|
65 j.alex 1.23 Uint32 queueId,
|
66 mike 1.24 Buffer& message,
|
67 j.alex 1.23 Boolean closeConnect);
|
68 mike 1.2
|
69 kumpf 1.7 void sendEMethodError(
|
70 j.alex 1.23 Uint32 queueId,
71 HttpMethod httpMethod,
72 const String& messageId,
73 const String& methodName,
74 const CIMException& cimException,
75 Boolean closeConnect);
|
76 kumpf 1.8
|
77 kumpf 1.10 void sendHttpError(
|
78 j.alex 1.23 Uint32 queueId,
79 const String& status,
80 const String& cimError = String::EMPTY,
81 const String& messageBody = String::EMPTY,
82 Boolean closeConnect = false);
|
83 mike 1.2
|
84 mday 1.5 virtual void handleEnqueue(Message *);
|
85 mike 1.2
|
86 mday 1.5 virtual void handleEnqueue();
|
87 mike 1.2
|
88 mday 1.5 void handleHTTPMessage(HTTPMessage* httpMessage);
|
89 mike 1.2
|
90 chuck 1.18 // l10n
|
91 mday 1.5 void handleMethodRequest(
|
92 j.alex 1.23 Uint32 queueId,
93 HttpMethod httpMethod,
94 char* content,
95 const String& requestUri,
96 const String& cimProtocolVersionInHeader,
97 const String& cimExportMethodInHeader,
98 const String& userName,
|
99 kumpf 1.27 const String& ipAddress,
|
100 kumpf 1.25 const AcceptLanguageList& httpAcceptLanguages,
101 const ContentLanguageList& httpContentLanguages,
|
102 j.alex 1.23 Boolean closeConnect);
|
103 mike 1.2
|
104 mday 1.5 CIMExportIndicationRequestMessage* decodeExportIndicationRequest(
105 Uint32 queueId,
106 XmlParser& parser,
107 const String& messageId,
108 const String& nameSpace);
|
109 mike 1.2
|
110 mday 1.5 /** Sets the flag to indicate whether or not the CIMServer is
111 shutting down.
112 */
113 void setServerTerminating(Boolean flag);
|
114 mike 1.2
|
115 mday 1.5 private:
|
116 mike 1.2
|
117 mday 1.5 MessageQueue* _outputQueue;
|
118 mike 1.2
|
119 mday 1.5 // Queue where responses should be enqueued.
120 Uint32 _returnQueueId;
121
122 // Flag to indicate whether or not the CIMServer is shutting down.
123 Boolean _serverTerminating;
|
124 j.alex 1.23
|
125 mike 1.2 };
126
127 PEGASUS_NAMESPACE_END
128
129 #endif /* Pegasus_CIMExportRequestDecoder_h */
|