|
1 /* |
|
2 * Copyright (c) 2007 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 class is responsible for all category tables (Artist, |
|
15 * Album, Genre, Composer). |
|
16 * |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 #ifndef MPXDBGENRE_H |
|
22 #define MPXDBGENRE_H |
|
23 |
|
24 // INCLUDES |
|
25 #include "mpxdbcategory.h" |
|
26 |
|
27 // CLASS FORWARDS |
|
28 class CMPXMedia; |
|
29 class CMPXMediaArray; |
|
30 class RSqlStatement; |
|
31 |
|
32 // CLASS DECLARATION |
|
33 |
|
34 /** |
|
35 * Responsible for managing all music databases |
|
36 * |
|
37 * @lib MPXDbPlugin.lib |
|
38 */ |
|
39 |
|
40 class CMPXDbGenre : |
|
41 public CMPXDbCategory |
|
42 { |
|
43 public: |
|
44 |
|
45 /** |
|
46 * Two-phased constructor. |
|
47 * @param aDbManager database manager to use for database interactions |
|
48 * @param aCategory identifies the category |
|
49 * @return New CMPXDbCategory instance. |
|
50 */ |
|
51 static CMPXDbGenre* NewL(CMPXDbManager& aDbManager, |
|
52 TMPXGeneralCategory aCategory); |
|
53 |
|
54 /** |
|
55 * Two-phased constructor. |
|
56 * @param aDbManager database manager to use for database interactions |
|
57 * @param aCategory identifies the category |
|
58 * @return New CMPXDbCategory instance on the cleanup stack. |
|
59 */ |
|
60 static CMPXDbGenre* NewLC(CMPXDbManager& aDbManager, |
|
61 TMPXGeneralCategory aCategory); |
|
62 |
|
63 /** |
|
64 * Destructor |
|
65 */ |
|
66 virtual ~CMPXDbGenre(); |
|
67 |
|
68 private: |
|
69 |
|
70 /** |
|
71 * C++ constructor. |
|
72 * @param aDbManager database manager to use for database interactions |
|
73 * @param aCategory identifies the category |
|
74 */ |
|
75 CMPXDbGenre(CMPXDbManager& aDbManager, TMPXGeneralCategory aCategory); |
|
76 |
|
77 /** |
|
78 * Second phase constructor. |
|
79 */ |
|
80 void ConstructL(); |
|
81 |
|
82 private: |
|
83 |
|
84 /** |
|
85 * Column indexes in the category tables |
|
86 */ |
|
87 enum TGenreColumns |
|
88 { |
|
89 EGenreUniqueId = KMPXTableDefaultIndex, |
|
90 EGenreName, |
|
91 EGenreSongCount, |
|
92 EGenreFieldCount |
|
93 }; |
|
94 |
|
95 private: // Data |
|
96 |
|
97 }; |
|
98 #endif // MPXDBGENRE_H |
|
99 |
|
100 // End of File |