21 |
21 |
22 #include <e32base.h> |
22 #include <e32base.h> |
23 #include "mesmrtaskfactory.h" |
23 #include "mesmrtaskfactory.h" |
24 |
24 |
25 class MESMRCalDbMgr; |
25 class MESMRCalDbMgr; |
26 class CMRMailboxUtils; |
|
27 |
26 |
28 /** |
27 /** |
29 * CESMRTaskFactory implements interface for creating ES MR tasks. |
28 * CESMRTaskFactory defines ECom plugin interface for creating ES MR tasks. |
30 * @see MESMRTaskFactory |
29 * @see MESMRTaskFactory |
31 * |
30 * |
32 * @lib esmrtasks.lib |
31 * @lib esmrtasks.lib |
33 */ |
32 */ |
34 NONSHARABLE_CLASS(CESMRTaskFactory) : public CBase, |
33 class CESMRTaskFactory : public CBase, |
35 public MESMRTaskFactory |
34 public MESMRTaskFactory |
36 { |
35 { |
37 public: // Construction and destruction |
36 public: // Construction and destruction |
38 /** |
37 /** |
39 * Creates and initialzes new ES MR task factory. |
38 * Creates and initialzes new ES MR task factory. |
40 * @param aCalDbMgr Reference to cal db manager. |
39 * @param aCalDbMgr Reference to cal db manager. |
41 * @param aMRMailboxUtils Reference to mailbox utilities. |
|
42 */ |
40 */ |
43 IMPORT_C static CESMRTaskFactory* NewL( |
41 inline static CESMRTaskFactory* NewL( |
44 MESMRCalDbMgr& aCalDbMgr, |
42 TESMRCalendarEventType aType, |
45 CMRMailboxUtils& aMRMailboxUtils ); |
43 MESMRCalDbMgr& aCalDbMgr ); |
46 |
44 |
47 /** |
45 /** |
48 * C++ destructor. |
46 * C++ destructor. |
49 */ |
47 */ |
50 ~CESMRTaskFactory(); |
48 inline ~CESMRTaskFactory(); |
51 |
49 |
52 public: // From MESMRTaskFactory |
50 public: // From MESMRTaskFactory |
53 MESMRTask* CreateTaskL( |
51 MESMRTask* CreateTaskL( |
54 TESMRCommand aCommand, |
52 TESMRCommand aCommand, |
55 MESMRMeetingRequestEntry& aEntry ); |
53 MESMRCalEntry& aEntry ) = 0; |
56 |
|
57 private: // Implementation |
|
58 CESMRTaskFactory( |
|
59 MESMRCalDbMgr& aCalDbMgr, |
|
60 CMRMailboxUtils& aMRMailboxUtils ); |
|
61 MESMRTask* CreateSendMRResponseViaMailTaskL( |
|
62 TESMRCommand aCommand, |
|
63 MESMRMeetingRequestEntry& aEntry ); |
|
64 MESMRTask* CreateSendMRTaskL( |
|
65 TESMRCommand aCommand, |
|
66 MESMRMeetingRequestEntry& aEntry ); |
|
67 MESMRTask* CreateDeleteMRTaskL( |
|
68 TESMRCommand aCommand, |
|
69 MESMRMeetingRequestEntry& aEntry ); |
|
70 MESMRTask* CreateStoreMRToLocalDBTaskL( |
|
71 TESMRCommand aCommand, |
|
72 MESMRMeetingRequestEntry& aEntry ); |
|
73 MESMRTask* CreateForwardAsMeetingTaskL( |
|
74 TESMRCommand aCommand, |
|
75 MESMRMeetingRequestEntry& aEntry ); |
|
76 MESMRTask* CreateForwardAsMailTaskL( |
|
77 MESMRMeetingRequestEntry& aEntry ); |
|
78 MESMRTask* CreateOrganizerDeleteMRTaskL( |
|
79 TESMRCommand aCommand, |
|
80 MESMRMeetingRequestEntry& aEntry ); |
|
81 MESMRTask* CreateAttendeeDeleteMRTaskL( |
|
82 TESMRCommand aCommand, |
|
83 MESMRMeetingRequestEntry& aEntry ); |
|
84 MESMRTask* CreateReplyAsMailTaskL( |
|
85 MESMRMeetingRequestEntry& aEntry, |
|
86 TBool aReplyAll); |
|
87 |
54 |
88 private: // Data |
55 private: // Data |
89 /* |
56 |
90 * Reference to cal db manager |
|
91 * Not own. |
|
92 */ |
|
93 MESMRCalDbMgr& iCalDbMgr; |
|
94 |
|
95 /** |
57 /** |
96 * Reference to mr mailbox utilities |
58 * iDtor_ID_Key Instance identifier key. When instance of an |
97 * Not own. |
59 * implementation is created by ECOM framework, the |
98 */ |
60 * framework will assign UID for it. The UID is used in |
99 CMRMailboxUtils& iMRMailboxUtils; |
61 * destructor to notify framework that this instance is |
|
62 * being destroyed and resources can be released. |
|
63 */ |
|
64 TUid iDtor_ID_Key; |
100 }; |
65 }; |
101 |
66 |
|
67 #include "cesmrtaskfactory.inl" |
|
68 |
102 #endif // C_ESMRTASKFACTORY_H |
69 #endif // C_ESMRTASKFACTORY_H |