|
1 /* |
|
2 * Copyright (c) 2006-2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: This file implements class CIpsPlgDeleteLocal. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // INCLUDE FILES |
|
20 |
|
21 #include "emailtrace.h" |
|
22 #include "ipsplgheaders.h" |
|
23 |
|
24 |
|
25 // ================= MEMBER FUNCTIONS ======================= |
|
26 |
|
27 // ---------------------------------------------------------------------------- |
|
28 // CIpsPlgDeleteLocal::CIpsPlgDeleteLocal |
|
29 // ---------------------------------------------------------------------------- |
|
30 // |
|
31 CIpsPlgDeleteLocal::CIpsPlgDeleteLocal( |
|
32 CMsvSession& aMsvSession, |
|
33 TRequestStatus& aObserverRequestStatus) |
|
34 : |
|
35 CImCacheManager(aMsvSession, aObserverRequestStatus) |
|
36 { |
|
37 FUNC_LOG; |
|
38 } |
|
39 |
|
40 // ---------------------------------------------------------------------------- |
|
41 // CIpsPlgDeleteLocal::ConstructL |
|
42 // ---------------------------------------------------------------------------- |
|
43 // |
|
44 void CIpsPlgDeleteLocal::ConstructL( |
|
45 CMsvEntrySelection& aMessageSelection ) |
|
46 { |
|
47 FUNC_LOG; |
|
48 CImCacheManager::ConstructL(); |
|
49 iMessageSelection = aMessageSelection.CopyL(); |
|
50 StartL( *iMessageSelection, iObserverRequestStatus ); |
|
51 } |
|
52 |
|
53 // ---------------------------------------------------------------------------- |
|
54 // CIpsPlgDeleteLocal::NewL |
|
55 // ---------------------------------------------------------------------------- |
|
56 // |
|
57 CIpsPlgDeleteLocal* CIpsPlgDeleteLocal::NewL( |
|
58 CMsvEntrySelection& aMessageSelection, |
|
59 CMsvSession& aMsvSession, |
|
60 TRequestStatus& aObserverRequestStatus) |
|
61 { |
|
62 FUNC_LOG; |
|
63 CIpsPlgDeleteLocal* self = |
|
64 new ( ELeave ) CIpsPlgDeleteLocal( |
|
65 aMsvSession, |
|
66 aObserverRequestStatus); |
|
67 |
|
68 CleanupStack::PushL( self ); |
|
69 self->ConstructL( aMessageSelection ); |
|
70 CleanupStack::Pop( self ); |
|
71 |
|
72 return self; |
|
73 }; |
|
74 |
|
75 // ---------------------------------------------------------------------------- |
|
76 // CIpsPlgDeleteLocal::~CIpsPlgDeleteLocal |
|
77 // ---------------------------------------------------------------------------- |
|
78 // |
|
79 CIpsPlgDeleteLocal::~CIpsPlgDeleteLocal() |
|
80 { |
|
81 FUNC_LOG; |
|
82 delete iMessageSelection; |
|
83 } |
|
84 |
|
85 // ---------------------------------------------------------------------------- |
|
86 // CIpsPlgDeleteLocal::Filter |
|
87 // ---------------------------------------------------------------------------- |
|
88 // |
|
89 TBool CIpsPlgDeleteLocal::Filter() const |
|
90 { |
|
91 FUNC_LOG; |
|
92 if ( iMessageSelection->Find( iCurrentEntry->Entry().Id() ) |
|
93 > KErrNotFound ) |
|
94 { |
|
95 return ETrue; |
|
96 } |
|
97 return EFalse; |
|
98 } |
|
99 |
|
100 // End of File |
|
101 |
|
102 |