author | Santosh V Patil <santosh.v.patil@nokia.com> |
Fri, 19 Feb 2010 15:03:34 +0530 | |
branch | ADM |
changeset 14 | 343c622c9f65 |
permissions | -rw-r--r-- |
14
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
1 |
/* |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
2 |
* Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies). |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
3 |
* All rights reserved. |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
4 |
* This component and the accompanying materials are made available |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
5 |
* under the terms of "Eclipse Public License v1.0" |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
6 |
* which accompanies this distribution, and is available |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html". |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
8 |
* |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
9 |
* Initial Contributors: |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
10 |
* Nokia Corporation - initial contribution. |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
11 |
* |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
12 |
* Contributors: |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
13 |
* |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
14 |
* Description: |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
15 |
* Functions to read from the config file. |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
16 |
* |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
17 |
* |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
18 |
*/ |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
19 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
20 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
21 |
#ifndef __CONFIG_H__ |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
22 |
#define __CONFIG_H__ |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
23 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
24 |
#include <e32def.h> |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
25 |
#include <f32file.h> |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
26 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
27 |
#include "globals.h" |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
28 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
29 |
// Configuration file containing the URL for the server. Stored in private directory. |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
30 |
_LIT(KConfigFile, "config.ini"); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
31 |
_LIT(KCfgTagUrl, "Url="); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
32 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
33 |
enum VersionResult |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
34 |
{ |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
35 |
EEqualVersion, |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
36 |
EGreaterFirstVersion, |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
37 |
EGreaterSecondVersion |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
38 |
}; |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
39 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
40 |
TInt ReadConfigFile(RFile& aFile, TDes& aBuffer, RArray< TPtrC >& aLineBuffer ); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
41 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
42 |
HBufC* ReadConfigFile( RFs& aFs, const TDesC& aFullPath, RArray< TPtrC >& aLineBuffer, TInt& aError ); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
43 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
44 |
TPtrC GetConfigValue( const TDesC& aTag, const RArray< TPtrC >& aLineBuffer, TInt& aError ); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
45 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
46 |
TInt CompareVersions(TVersion& version1,TVersion& version2); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
47 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
48 |
TBool SetVersion(const TDesC8& aVersionPtr, TVersion& aVer); |
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
49 |
|
343c622c9f65
Contribution of bootstrap component of the Nokia Smart Installer (beta)
Santosh V Patil <santosh.v.patil@nokia.com>
parents:
diff
changeset
|
50 |
#endif |