|
1 // Copyright (c) 1999-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 #include <msvscheduledentry.h> |
|
17 |
|
18 #include <e32base.h> |
|
19 #include <msvstd.h> |
|
20 #include <msventry.h> |
|
21 |
|
22 #include <msvschedulesend.h> |
|
23 |
|
24 /** |
|
25 Constructor. |
|
26 |
|
27 @param aEntry |
|
28 Scheduled message. |
|
29 */ |
|
30 |
|
31 EXPORT_C CMsvScheduledEntry::CMsvScheduledEntry(const TMsvEntry& aEntry) |
|
32 : iEntry(aEntry) |
|
33 { |
|
34 } |
|
35 |
|
36 |
|
37 /** |
|
38 Gets the message entry. |
|
39 |
|
40 @param aEntry |
|
41 On return, the message entry. |
|
42 */ |
|
43 |
|
44 EXPORT_C void CMsvScheduledEntry::Entry(TMsvEntry& aEntry) const |
|
45 { |
|
46 aEntry.iDate = iEntry.iDate; |
|
47 aEntry.SetScheduled(iEntry.Scheduled()); |
|
48 aEntry.SetSendingState(iEntry.SendingState()); |
|
49 aEntry.SetFailed(iEntry.Failed()); |
|
50 } |
|
51 |
|
52 |
|
53 /** |
|
54 Stores the object. |
|
55 |
|
56 @param aStore |
|
57 Store to write to. |
|
58 |
|
59 @leave TMsvEntryScheduleData::StoreL() |
|
60 @leave RecipientsStoreL() |
|
61 */ |
|
62 |
|
63 EXPORT_C void CMsvScheduledEntry::StoreL(CMsvStore& aStore) const |
|
64 { |
|
65 if (iData.IsReset()) |
|
66 { |
|
67 iData.RemoveL(aStore); |
|
68 } |
|
69 else |
|
70 { |
|
71 iData.StoreL(aStore); |
|
72 } |
|
73 |
|
74 RecipientsStoreL(aStore); |
|
75 } |
|
76 |
|
77 |
|
78 /** |
|
79 Restores the object. |
|
80 |
|
81 @param aStore |
|
82 Store to read from. |
|
83 |
|
84 @leave TMsvEntryScheduleData::RestoreL() |
|
85 @leave RecipientsRestoreL() |
|
86 */ |
|
87 |
|
88 EXPORT_C void CMsvScheduledEntry::RestoreL(CMsvStore& aStore) |
|
89 { |
|
90 iData.RestoreL(aStore); |
|
91 RecipientsRestoreL(aStore); |
|
92 } |
|
93 |
|
94 |
|
95 /** |
|
96 Gets the entry's pending conditions flag. |
|
97 |
|
98 @return |
|
99 The entry's pending conditions flag. |
|
100 */ |
|
101 EXPORT_C TBool CMsvScheduledEntry::PendingConditions() const |
|
102 { |
|
103 return iEntry.PendingConditions(); |
|
104 } |
|
105 |
|
106 /** |
|
107 sets the entry's pending conditions flag. |
|
108 |
|
109 @param aPendingConitions |
|
110 The entry's pending conditions flag. |
|
111 */ |
|
112 EXPORT_C void CMsvScheduledEntry::SetPendingConditions(TBool aPendingConditions) |
|
113 { |
|
114 iEntry.SetPendingConditions(aPendingConditions); |
|
115 } |
|
116 |