|
1 // Copyright (c) 2000-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 |
|
18 @publishedPartner |
|
19 @released |
|
20 */ |
|
21 |
|
22 #ifndef __SISLPUSHMSGUTILS_H__ |
|
23 #define __SISLPUSHMSGUTILS_H__ |
|
24 |
|
25 #include <e32base.h> |
|
26 #include <msvapi.h> |
|
27 #include <pushentry.h> |
|
28 #include <push/cwappushmsgutils.h> |
|
29 |
|
30 /** push folder description */ |
|
31 _LIT(KPushFolderDescription, "WAP Push Msg Folder Entry"); |
|
32 |
|
33 class MWapPushLog; |
|
34 class CWapPushMessageFilter; |
|
35 |
|
36 |
|
37 /** |
|
38 Panic codes for Push Message Utils. |
|
39 |
|
40 @publishedPartner |
|
41 @released |
|
42 */ |
|
43 enum TSISLPushMsgUtilsPanic { |
|
44 /** Invlaid Push message */ |
|
45 ESISLPushMsgUtilsNotValidPushMsg, |
|
46 /** Not SI message */ |
|
47 ESISLPushMsgUtilsNotSiMsg |
|
48 }; |
|
49 |
|
50 /** push message ultils panic */ |
|
51 _LIT(KSISLPushMsgUtilsPanicTitle, "CSISLPushMsgUtils"); |
|
52 |
|
53 /** |
|
54 SI and SL Push message utility class used by the SI and SL Content Handlers. |
|
55 The class has functions for locating and creating WAP Push Service. |
|
56 |
|
57 Contains a CMsvSession object, and allows other objects to get a reference to |
|
58 a session without having to inherit from the MMsvSessionObserver class. |
|
59 |
|
60 @see CSIContentHandler |
|
61 @see CSLContentHandler |
|
62 |
|
63 @publishedPartner |
|
64 @released |
|
65 */ |
|
66 class CSISLPushMsgUtils: public CWapPushMsgUtils |
|
67 { |
|
68 public: |
|
69 IMPORT_C static CSISLPushMsgUtils* NewL(); |
|
70 IMPORT_C virtual ~CSISLPushMsgUtils(); |
|
71 |
|
72 IMPORT_C CMsvEntrySelection* FindSiIdLC (const TDesC& aSiId) ; |
|
73 IMPORT_C TMsvId FindUrlL(const TDesC& aUrl, TUid aPushType); |
|
74 IMPORT_C TInt GetActionL(TMsvId aId); |
|
75 IMPORT_C const TTime GetExpiryL(TMsvId aId); |
|
76 IMPORT_C TMsvId GetHighestActionL(TUid aPushType); |
|
77 IMPORT_C TMsvId GetNextExpiryL(); |
|
78 |
|
79 IMPORT_C void DeleteEntryL(TMsvId aId); |
|
80 IMPORT_C void DeleteEntryNowL(TMsvId aId); |
|
81 IMPORT_C void GetPushMsgFolderIdL(TMsvId& rFolderId); |
|
82 |
|
83 public: |
|
84 inline TTime GetCreationDateL(TMsvId aId); |
|
85 inline TTime GetTransmissionDateL(TMsvId aId); |
|
86 |
|
87 private: |
|
88 CSISLPushMsgUtils(); |
|
89 void ConstructL(); |
|
90 |
|
91 TMsvId CreatePushMsgFolderL(); |
|
92 CPushMsgEntryBase* GetPushMsgEntryL(const TUid aPushType); |
|
93 CMsvEntrySelection* GetChildrenWithMtmLC(TUid aMtm); |
|
94 TTime GetDateL(TMsvId aId, const TUid aPushType); |
|
95 }; |
|
96 |
|
97 |
|
98 #include <push/sislpushmsgutils.inl> |
|
99 |
|
100 #endif // __SISLPUSHMSGUTILS_H__ |