1 /* |
|
2 * Copyright (c) 2002-2009 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: Capability service controller |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef _CAPINFO_H_ |
|
20 #define _CAPINFO_H_ |
|
21 |
|
22 #include <e32base.h> |
|
23 #include <f32file.h> |
|
24 |
|
25 #include "caputils.h" |
|
26 |
|
27 // |
|
28 // CCapInfo creates capability document |
|
29 // |
|
30 // |
|
31 |
|
32 class CCapList; |
|
33 class CStringList; |
|
34 class TSConSolutionInfo; |
|
35 class CSconVersionInfo; |
|
36 |
|
37 NONSHARABLE_CLASS( CCapInfo ) : public CBase |
|
38 { |
|
39 public: |
|
40 static CCapInfo* NewL(); |
|
41 ~CCapInfo(); |
|
42 private: |
|
43 CCapInfo(); |
|
44 void ConstructL(); |
|
45 |
|
46 public: |
|
47 void CapabilityDocumentL( CBufFlat* aBuf ); |
|
48 |
|
49 private: |
|
50 CCapList* CapList(); |
|
51 void SetCapabilityBuf( CBufFlat* aBuf ); |
|
52 |
|
53 void GeneralInfoL(); |
|
54 void MemoryInfoL(); |
|
55 void WriteMemoryInfoL( TMemoryInfo& aInfo ); |
|
56 void ServiceInfoL( const TDesC& aDir, const RArray<TFileName>& aExcludeList, |
|
57 RArray<TFileName>& aFilesAdded ); |
|
58 void FolderServiceL(); |
|
59 |
|
60 void SyncSolutionsServiceL(); |
|
61 void WriteSyncSolutionsServiceL( const TSConSolutionInfo& aCalendar, |
|
62 const TSConSolutionInfo& aContact, |
|
63 const TSConSolutionInfo& aSms, |
|
64 const TSConSolutionInfo& aBookmark ); |
|
65 void WriteSolutionTagL( const TDesC& aContentName, const TSConSolutionInfo& aSolution ); |
|
66 |
|
67 void WriteFolderL( const TDesC& aType, const TDesC& aFullName, const TDesC& aMemory ); |
|
68 |
|
69 void WriteValueL( TInt aId, const TDesC& aValue ); |
|
70 void WriteBigValueL( TInt aId, const TDesC& aValue ); |
|
71 void WriteValueL( TInt aId, TInt64 aValue ); |
|
72 void WriteTagL( TInt aId, TInt aType ); |
|
73 void WriteAttributeL( TInt aId, const TDesC& aVersion, const TDesC& aDate ); |
|
74 void WriteL( const TDesC& aText ); |
|
75 |
|
76 void WriteFromListL( CStringList* aList ); |
|
77 void WriteNewLineL(); |
|
78 |
|
79 void FormatElement( TDes& aText ); |
|
80 void AddFormatText( TDes& aText, TInt aNum ) const; |
|
81 |
|
82 private: |
|
83 RFs iFsSession; // has |
|
84 CCapList* iCapList; // has |
|
85 HBufC8* iHeapBuf; // has |
|
86 TBuf<KMaxSize> iBuf; |
|
87 TIdStack iIdStack; |
|
88 |
|
89 CBufFlat* iCapabilityBuf; // uses |
|
90 CSconVersionInfo* iSconInfo; |
|
91 }; |
|
92 |
|
93 #endif // CCapability |
|
94 |
|