|
1 /* |
|
2 * Copyright (c) 2002 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: |
|
15 * MFLDEntryFormatter defines an abstract interface to create |
|
16 * formatted presentations of directory entries |
|
17 * |
|
18 * |
|
19 */ |
|
20 |
|
21 |
|
22 |
|
23 #ifndef __MFLDENTRYFORMATTER_H__ |
|
24 #define __MFLDENTRYFORMATTER_H__ |
|
25 |
|
26 // INTERNAL INCLUDES |
|
27 |
|
28 // EXTERNAL INCLUDES |
|
29 #include <e32base.h> |
|
30 |
|
31 // FORWARD DECLARATIONS |
|
32 class CFLDEntryReference; |
|
33 |
|
34 // CLASS DEFINITION |
|
35 |
|
36 /** |
|
37 * MFLDEntryFormatter defines an abstract interface to create |
|
38 * formatted presentations of directory entries |
|
39 */ |
|
40 class MFLDEntryFormatter |
|
41 { |
|
42 public: // Constructors and destructor |
|
43 |
|
44 /** |
|
45 * Destructor. |
|
46 */ |
|
47 virtual ~MFLDEntryFormatter() {} |
|
48 |
|
49 public: // New functions |
|
50 |
|
51 /** |
|
52 * Formats a single entry |
|
53 * @param aEntry The entry to be formatted |
|
54 */ |
|
55 virtual void FormatL( CFLDEntryReference& aEntry ) = 0; |
|
56 |
|
57 /** |
|
58 * Formats a null item text (see CFLDFileListModel::InsertNullItemL). |
|
59 * Default implementation does no modifications to the given text |
|
60 * (to maintain BC). |
|
61 * @param aText The text to be formatted. |
|
62 * @return Returns an allocated formatted HBufC. |
|
63 * Ownership is returned to the caller. |
|
64 * @since Series 60 2.6 |
|
65 */ |
|
66 virtual HBufC* FormatTextLC( const TDesC& aText ) |
|
67 { return aText.AllocLC(); } |
|
68 |
|
69 }; |
|
70 |
|
71 #endif // __MFLDENTRYFORMATTER_H__ |
|
72 |
|
73 // End of File |