|
1 // Copyright (c) 2001-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 /** |
|
17 @file CRxData.h |
|
18 @warning : This file contains Rose Model ID comments - please do not delete |
|
19 */ |
|
20 |
|
21 #ifndef __CRXDATA_H__ |
|
22 #define __CRXDATA_H__ |
|
23 |
|
24 // System includes |
|
25 #include <e32base.h> |
|
26 #include <http/framework/cprottransaction.h> |
|
27 #include <http/mhttpdatasupplier.h> |
|
28 #include <http/rhttpsession.h> // this include is needed to ensure that the <rhttp.inl> is compiled by gcc... |
|
29 |
|
30 // Forward declarations |
|
31 class MRxDataObserver; |
|
32 |
|
33 |
|
34 //##ModelId=3B1E52AB0087 |
|
35 class CRxData : public CBase, public MHTTPDataSupplier |
|
36 /** |
|
37 An abstract base class for the decoding of response data received by a |
|
38 protocol handler. |
|
39 @publishedAll |
|
40 @released |
|
41 */ |
|
42 { |
|
43 public: |
|
44 |
|
45 /** Intended Usage: Destructor - cleans up and releases resources to the system |
|
46 */ |
|
47 IMPORT_C |
|
48 //##ModelId=3B1E52AB00ED |
|
49 virtual ~CRxData(); |
|
50 |
|
51 /** Intended Usage: Obtain the protocol transaction whose request part is represented |
|
52 as encoded data by this object. |
|
53 @return The protocol transaction object |
|
54 */ |
|
55 IMPORT_C |
|
56 //##ModelId=3B1E52AB00EC |
|
57 CProtTransaction& ProtTrans(); |
|
58 |
|
59 public: |
|
60 |
|
61 /** Intended Usage: Resets the received data object to its initial state following |
|
62 construction. This method must be implemented for specific sub- |
|
63 classes of received data. |
|
64 @post The object is reset. |
|
65 */ |
|
66 //##ModelId=3BA60048014B |
|
67 virtual void ResetRxData() = 0; |
|
68 |
|
69 protected: |
|
70 |
|
71 /** Intended Usage: Default constructor - creates an Rx data object not associated |
|
72 with any protocol transaction. |
|
73 */ |
|
74 IMPORT_C |
|
75 //##ModelId=3A914E5F008F |
|
76 CRxData(); |
|
77 |
|
78 /** Intended Usage: Normal constructor, of a CRxData that corresponds to the supplied |
|
79 protocol transaction, and which sends status updates to the supplied |
|
80 observer interface, |
|
81 @param aProtTrans (in) The transaction for which this object |
|
82 represents the transmitted data. |
|
83 @param aObserver (in) The object's observer. |
|
84 */ |
|
85 IMPORT_C CRxData(CProtTransaction& aProtTrans, MRxDataObserver& aObserver); |
|
86 |
|
87 /** Intended Usage: Second phase construction, default |
|
88 */ |
|
89 IMPORT_C |
|
90 //##ModelId=3B1E52AB00BA |
|
91 void ConstructL(); |
|
92 |
|
93 protected: |
|
94 |
|
95 /** The protocol transaction for which this object represents the encoded received data |
|
96 */ |
|
97 //##ModelId=3B1E52AB00B2 |
|
98 CProtTransaction* iProtTrans; |
|
99 |
|
100 /** This object's observer, to whom we forward status information |
|
101 */ |
|
102 //##ModelId=3B1E7738028B |
|
103 MRxDataObserver* iObserver; |
|
104 |
|
105 private: // methods |
|
106 |
|
107 /** Intended Usage: Reserve a slot in the v-table to preserve future BC |
|
108 */ |
|
109 //##ModelId=3C4C37DA0007 |
|
110 inline virtual void Reserved1(); |
|
111 |
|
112 /** Intended Usage: Reserve a slot in the v-table to preserve future BC |
|
113 */ |
|
114 //##ModelId=3C4C37D903DB |
|
115 inline virtual void Reserved2(); |
|
116 }; |
|
117 |
|
118 |
|
119 inline void CRxData::Reserved1() |
|
120 {} |
|
121 inline void CRxData::Reserved2() |
|
122 {} |
|
123 |
|
124 |
|
125 #endif // __CRXDATA_H__ |
|
126 |