|
1 /* |
|
2 * Copyright (c) 2007-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 module contains the implementation of CIAUpdate class |
|
15 * member functions. |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 // INCLUDES |
|
22 #include <iaupdate.h> |
|
23 #include "iaupdatemanager.h" |
|
24 |
|
25 |
|
26 EXPORT_C CIAUpdate* CIAUpdate::NewL( MIAUpdateObserver& aObserver ) |
|
27 { |
|
28 CIAUpdate* self = CIAUpdate::NewLC( aObserver ); |
|
29 CleanupStack::Pop( self ); |
|
30 return self; |
|
31 } |
|
32 |
|
33 EXPORT_C CIAUpdate* CIAUpdate::NewLC( MIAUpdateObserver& aObserver ) |
|
34 { |
|
35 CIAUpdate* self = new( ELeave ) CIAUpdate(); |
|
36 CleanupStack::PushL( self ); |
|
37 self->ConstructL( aObserver ); |
|
38 return self; |
|
39 } |
|
40 |
|
41 |
|
42 CIAUpdate::CIAUpdate() |
|
43 : CBase() |
|
44 { |
|
45 |
|
46 } |
|
47 |
|
48 void CIAUpdate::ConstructL( MIAUpdateObserver& aObserver ) |
|
49 { |
|
50 iUpdateManager = CIAUpdateManager::NewL( aObserver ); |
|
51 } |
|
52 |
|
53 |
|
54 EXPORT_C CIAUpdate::~CIAUpdate() |
|
55 { |
|
56 delete iUpdateManager; |
|
57 } |
|
58 |
|
59 |
|
60 EXPORT_C void CIAUpdate::CheckUpdates( const CIAUpdateParameters& aUpdateParameters ) |
|
61 { |
|
62 // Forward request to the actual updater |
|
63 UpdateManager().CheckUpdates( aUpdateParameters ); |
|
64 } |
|
65 |
|
66 |
|
67 EXPORT_C void CIAUpdate::ShowUpdates( const CIAUpdateParameters& aUpdateParameters ) |
|
68 { |
|
69 // Forward request to the actual updater |
|
70 UpdateManager().ShowUpdates( aUpdateParameters ); |
|
71 } |
|
72 |
|
73 |
|
74 EXPORT_C void CIAUpdate::Update( const CIAUpdateParameters& aUpdateParameters ) |
|
75 { |
|
76 // Forward request to the actual updater |
|
77 UpdateManager().Update( aUpdateParameters ); |
|
78 } |
|
79 |
|
80 |
|
81 EXPORT_C void CIAUpdate::UpdateQuery() |
|
82 { |
|
83 UpdateManager().UpdateQuery(); |
|
84 } |
|
85 |
|
86 |
|
87 CIAUpdateManager& CIAUpdate::UpdateManager() const |
|
88 { |
|
89 return *iUpdateManager; |
|
90 } |