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