17 |
17 |
18 |
18 |
19 #ifndef ROHANDLERDMGRWRAPPER_H |
19 #ifndef ROHANDLERDMGRWRAPPER_H |
20 #define ROHANDLERDMGRWRAPPER_H |
20 #define ROHANDLERDMGRWRAPPER_H |
21 |
21 |
22 #include <e32base.h> |
22 namespace Roap |
23 #include <f32file.h> |
23 { |
24 |
24 class MRoapObserver; |
25 #include <RoapObserver.h> |
25 } |
26 #include <RoapEng.h> |
|
27 |
|
28 #include <qobject.h> |
|
29 #include <downloadmanager.h> |
|
30 #include <download.h> |
|
31 |
26 |
32 class CDRMRights; |
27 class CDRMRights; |
33 class QRoHandlerDMgrEventHandler; |
28 |
|
29 class MHttpDownloadMgrObserver; |
34 |
30 |
35 class MRoHandlerDMgrWrapper |
31 class MRoHandlerDMgrWrapper |
36 { |
32 { |
|
33 |
37 public: |
34 public: |
38 virtual void HandleRoapTriggerL( const TDesC8& aTrigger ) = 0; |
35 virtual void HandleRoapTriggerL( const TDesC8& aTrigger ) = 0; |
|
36 |
|
37 virtual void DownloadAndHandleRoapTriggerL( const HBufC8* aUrl ) = 0; |
|
38 |
|
39 virtual void DownloadAndHandleRoapTriggerFromPrUrlL( const HBufC8* aUrl ) = 0; |
|
40 |
39 }; |
41 }; |
40 |
42 |
41 /** |
43 /** |
42 * Class for downloading ROAP triggers |
44 * Class for downloading ROAP triggers |
43 * |
45 * |
44 */ |
46 */ |
45 class CRoHandlerDMgrWrapper: |
47 class CRoHandlerDMgrWrapper: |
46 public CActive, // Now active |
48 public CActive, // Now active |
|
49 public MHttpDownloadMgrObserver, |
47 public Roap::MRoapObserver, |
50 public Roap::MRoapObserver, |
48 public MRoHandlerDMgrWrapper |
51 public MRoHandlerDMgrWrapper |
49 { |
52 { |
50 private: |
53 private: |
51 enum TMeterState |
54 enum TMeterState |
73 * @since S60 3.2 |
76 * @since S60 3.2 |
74 * @param aUrl URL of ROAP trigger |
77 * @param aUrl URL of ROAP trigger |
75 */ |
78 */ |
76 void HandleRoapTriggerL( const TDesC8& aTrigger ); |
79 void HandleRoapTriggerL( const TDesC8& aTrigger ); |
77 |
80 |
|
81 void DownloadAndHandleRoapTriggerL( const HBufC8* aUrl ); |
|
82 |
|
83 void DownloadAndHandleRoapTriggerFromPrUrlL( const HBufC8* aUrl ); |
|
84 |
|
85 |
|
86 // from base class MHttpDownloadMgrObserver |
|
87 |
|
88 /** |
|
89 * From MHttpDownloadMgrObserver. |
|
90 * Handle download manager events |
|
91 * |
|
92 * @since S60 3.2 |
|
93 * @param aDownload the download |
|
94 * @param aEvent the event |
|
95 */ |
|
96 void HandleDMgrEventL( RHttpDownload& aDownload, THttpDownloadEvent aEvent ); |
|
97 |
78 // From Roap::MRoapObserver |
98 // From Roap::MRoapObserver |
79 /** |
99 /** |
80 * ConnectionConfL |
100 * ConnectionConfL |
81 * @return ETrue: the network can be establish |
101 * @return ETrue: the network can be establish |
82 * EFalse: the ROAP transaction is canceled |
102 * EFalse: the ROAP transaction is canceled |