|
1 /** @file |
|
2 * Copyright (c) 2005-2006 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: Element table data handler |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef UPNPRESOURCESBEAN_H |
|
20 #define UPNPRESOURCESBEAN_H |
|
21 |
|
22 // INCLUDES |
|
23 #include "upnptablebean.h" |
|
24 #include <e32base.h> |
|
25 #include <d32dbms.h> |
|
26 |
|
27 class CUpnpElement; |
|
28 |
|
29 // CLASS DECLARATION |
|
30 /** |
|
31 * Stores the data of resources table row. |
|
32 * |
|
33 * @lib AVContentDirectory.lib |
|
34 * @since Series60 3.1 |
|
35 */ |
|
36 class CUpnpResourcesBean: public CUpnpTableBean |
|
37 { |
|
38 public: // Constructors and destructor |
|
39 |
|
40 /** |
|
41 * Two-phased constructor. |
|
42 */ |
|
43 static CUpnpResourcesBean* NewLC(); |
|
44 static CUpnpResourcesBean* NewL(const RDbRowSet& aRowSet); |
|
45 static CUpnpResourcesBean* NewLC(const RDbRowSet& aRowSet); |
|
46 |
|
47 /** |
|
48 * Destructor. |
|
49 */ |
|
50 virtual ~CUpnpResourcesBean(); |
|
51 |
|
52 public: // New functions |
|
53 /** |
|
54 * Sets value. |
|
55 * @since Series S60 3.0 |
|
56 * @param value of in the element table |
|
57 */ |
|
58 void SetL(const RDbRowSet& aRowSet); |
|
59 |
|
60 /** |
|
61 * Sets iId value. |
|
62 * @since Series S60 3.0 |
|
63 * @param aId value of rsc_id in the 'shareMap' table |
|
64 */ |
|
65 void SetId(TInt64 aId); |
|
66 |
|
67 /** |
|
68 * Sets iObjectId value. |
|
69 * @since Series S60 3.0 |
|
70 * @param aObjectId value of rsc_object_id in the 'shareMap' table |
|
71 */ |
|
72 void SetObjectId(TInt aObjectId); |
|
73 |
|
74 /** |
|
75 * Sets iPath value. |
|
76 * @since Series S60 3.0 |
|
77 * @param aPath value of rsc_path in the 'resources' table |
|
78 */ |
|
79 void SetPathL(const TDesC& aPath); |
|
80 void SetPathL(const TDesC8& aPath); |
|
81 |
|
82 /** |
|
83 * Sets iIsReadonly value. |
|
84 * @since Series S60 3.0 |
|
85 * @param IsReadonly value of rsc_is_readonly in the 'resources' table |
|
86 */ |
|
87 void SetIsReadonly(TBool aIsReadonly); |
|
88 |
|
89 /** |
|
90 * Sets iIsThumbnail value. |
|
91 * @since Series S60 3.0 |
|
92 * @param IsThumbnail value of rsc_is_thumbnail in the 'resources' table |
|
93 */ |
|
94 void SetIsThumbnail(TBool aIsThumbnail); |
|
95 |
|
96 /** |
|
97 * Gets iId value. |
|
98 * @since Series S60 3.0 |
|
99 * @return Gets the value of iId |
|
100 */ |
|
101 TInt64 Id() const; |
|
102 |
|
103 /** |
|
104 * Gets iObjectId value. |
|
105 * @since Series S60 3.0 |
|
106 * @return Gets the value of iObjectId |
|
107 */ |
|
108 TInt ObjectId() const; |
|
109 |
|
110 /** |
|
111 * Gets iPath value. |
|
112 * @since Series S60 3.0 |
|
113 * @return Gets the value of iPath |
|
114 */ |
|
115 TDesC& Path() const; |
|
116 |
|
117 |
|
118 /** |
|
119 * Gets iIsReadonly value. |
|
120 * @since Series S60 3.0 |
|
121 * @return Gets the value of iIsReadonly |
|
122 */ |
|
123 TInt IsReadonly() const; |
|
124 |
|
125 /** |
|
126 * Gets iIsThumbnail value. |
|
127 * @since Series S60 3.0 |
|
128 * @return Gets the value of iIsThumbnail |
|
129 */ |
|
130 TInt IsThumbnail() const; |
|
131 |
|
132 private: |
|
133 |
|
134 /** |
|
135 * C++ default constructor. |
|
136 */ |
|
137 CUpnpResourcesBean(); |
|
138 |
|
139 /** |
|
140 * By default Symbian 2nd phase constructor is private. |
|
141 */ |
|
142 void ConstructL(); |
|
143 |
|
144 private: // Data |
|
145 // Id |
|
146 TInt64 iId; |
|
147 // ObjectId |
|
148 TInt iObjectId; |
|
149 // Path |
|
150 HBufC* iPath; |
|
151 // |
|
152 TInt iIsReadonly; |
|
153 // |
|
154 TInt iIsThumbnail; |
|
155 }; |
|
156 |
|
157 // inline functions |
|
158 #include"upnpresourcesbean.inl" |
|
159 |
|
160 #endif // UPNPRESOURCESBEAN_H |
|
161 // End of File |