|
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: Contains MNcdNodeSeenFolder |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef M_NCDNODESEENFOLDER_H |
|
20 #define M_NCDNODESEENFOLDER_H |
|
21 |
|
22 #include "catalogsbase.h" |
|
23 #include "ncdinterfaceids.h" |
|
24 #include "catalogsarray.h" |
|
25 |
|
26 class MNcdNode; |
|
27 |
|
28 /** |
|
29 * This interface provides functions to obtain unseen child nodes of a folder and |
|
30 * to set them seen. This interface can be queried from a folder node. |
|
31 * |
|
32 * |
|
33 */ |
|
34 class MNcdNodeSeenFolder : public virtual MCatalogsBase |
|
35 { |
|
36 |
|
37 public: |
|
38 |
|
39 /** |
|
40 * Unique identifier for the interface, required for all MCatalogsBase interfaces. |
|
41 * |
|
42 * |
|
43 */ |
|
44 enum { KInterfaceUid = ENcdNodeSeenFolderUid }; |
|
45 |
|
46 /** |
|
47 * Sets the child nodes of the folder as seen. Only the immediate children are set. |
|
48 * |
|
49 * @leave System wide error code. |
|
50 */ |
|
51 virtual void SetContentsSeenL() = 0; |
|
52 |
|
53 /** |
|
54 * Returns the number of new child nodes. All the nodes that are unseen are |
|
55 * regarded as new. |
|
56 * |
|
57 * @param aLevels The number of node hierarchy levels the new nodes are searched from. |
|
58 * 1 means only the children of this node are searched. |
|
59 * @return The number of new items. |
|
60 * @leave System wide error code. |
|
61 */ |
|
62 virtual TInt NewCountL( TInt aLevels ) const = 0; |
|
63 |
|
64 /** |
|
65 * Returns an array of the new child nodes. All the nodes that are unseen are |
|
66 * regarded as new. |
|
67 * |
|
68 * The nodes in the array are counted, they must be released after use. |
|
69 * |
|
70 * @param aLevels The number of node hierarchy levels the new nodes are searched from. |
|
71 * 1 means only the children of this node are searched. |
|
72 */ |
|
73 virtual RCatalogsArray<MNcdNode> NewNodesL( TInt aLevels ) const = 0; |
|
74 |
|
75 protected: |
|
76 |
|
77 /** |
|
78 * Destructor. |
|
79 * |
|
80 * @see MCatalogsBase::~MCatalogsBase |
|
81 */ |
|
82 virtual ~MNcdNodeSeenFolder() {} |
|
83 |
|
84 }; |
|
85 |
|
86 |
|
87 #endif // M_NCDNODESEENFOLDER_H |