|
1 /* |
|
2 * Copyright (c) 2005-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: javaregistryentry implementation |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #include "javaregistryentry.h" |
|
20 #include "logger.h" |
|
21 #include "writeablejavaregistryentry.h" |
|
22 |
|
23 using namespace Java; |
|
24 using namespace Java::Manager::Registry; |
|
25 |
|
26 // ============================ MEMBER FUNCTIONS ============================== |
|
27 |
|
28 // --------------------------------------------------------------------------- |
|
29 // CJavaRegistryEntry::CJavaRegistryEntry |
|
30 // --------------------------------------------------------------------------- |
|
31 // |
|
32 CJavaRegistryEntry::CJavaRegistryEntry |
|
33 (CWriteableJavaRegistryEntry* aWritableEntry) : |
|
34 iWritableEntry(aWritableEntry) |
|
35 { |
|
36 } |
|
37 |
|
38 // --------------------------------------------------------------------------- |
|
39 // CJavaRegistryEntry::Uid |
|
40 // --------------------------------------------------------------------------- |
|
41 // |
|
42 EXPORT_C TUid CJavaRegistryEntry::Uid() const |
|
43 { |
|
44 JELOG2(EJavaStorage); |
|
45 return WritableEntry()->Uid(); |
|
46 } |
|
47 |
|
48 // --------------------------------------------------------------------------- |
|
49 // CJavaRegistryEntry::Name |
|
50 // --------------------------------------------------------------------------- |
|
51 // |
|
52 EXPORT_C const TDesC& CJavaRegistryEntry::Name() const |
|
53 { |
|
54 JELOG2(EJavaStorage); |
|
55 return WritableEntry()->Name(); |
|
56 } |
|
57 |
|
58 // --------------------------------------------------------------------------- |
|
59 // CJavaRegistryEntry::Type |
|
60 // --------------------------------------------------------------------------- |
|
61 // |
|
62 EXPORT_C TJavaRegistryEntryType CJavaRegistryEntry::Type() const |
|
63 { |
|
64 JELOG2(EJavaStorage); |
|
65 return WritableEntry()->Type(); |
|
66 } |
|
67 |
|
68 |
|
69 // --------------------------------------------------------------------------- |
|
70 // CJavaRegistryEntry::DriveL |
|
71 // --------------------------------------------------------------------------- |
|
72 // |
|
73 EXPORT_C TDriveNumber CJavaRegistryEntry::Drive() const |
|
74 { |
|
75 JELOG2(EJavaStorage); |
|
76 return WritableEntry()->Drive(); |
|
77 } |
|
78 |
|
79 |
|
80 // --------------------------------------------------------------------------- |
|
81 // CJavaRegistryEntry::NumberOfCertificateChains |
|
82 // --------------------------------------------------------------------------- |
|
83 // |
|
84 EXPORT_C TInt CJavaRegistryEntry::NumberOfCertificateChains() const |
|
85 { |
|
86 JELOG2(EJavaStorage); |
|
87 return WritableEntry()->NumberOfCertificateChains(); |
|
88 } |
|
89 |
|
90 |
|
91 // --------------------------------------------------------------------------- |
|
92 // CJavaRegistryEntry::CertificateChain |
|
93 // --------------------------------------------------------------------------- |
|
94 // |
|
95 EXPORT_C const TDesC8& CJavaRegistryEntry::CertificateChain( |
|
96 TInt aChain) const |
|
97 { |
|
98 JELOG2(EJavaStorage); |
|
99 return WritableEntry()->CertificateChain(aChain); |
|
100 } |
|
101 |
|
102 |
|
103 // --------------------------------------------------------------------------- |
|
104 // CJavaRegistryEntry::DrmContentId |
|
105 // --------------------------------------------------------------------------- |
|
106 // |
|
107 EXPORT_C const TDesC& CJavaRegistryEntry::DrmContentId() const |
|
108 { |
|
109 JELOG2(EJavaStorage); |
|
110 return WritableEntry()->DrmContentId(); |
|
111 } |
|
112 |
|
113 |
|
114 // --------------------------------------------------------------------------- |
|
115 // CJavaRegistryEntry::~CJavaRegistryEntry |
|
116 // --------------------------------------------------------------------------- |
|
117 // |
|
118 CJavaRegistryEntry::~CJavaRegistryEntry() |
|
119 { |
|
120 if (iWritableEntry) |
|
121 { |
|
122 delete iWritableEntry; |
|
123 iWritableEntry = NULL; |
|
124 } |
|
125 } |
|
126 |
|
127 // --------------------------------------------------------------------------- |
|
128 // CJavaRegistryEntry::WritableEntry |
|
129 // --------------------------------------------------------------------------- |
|
130 // |
|
131 CWriteableJavaRegistryEntry* CJavaRegistryEntry::WritableEntry() const |
|
132 { |
|
133 return iWritableEntry; |
|
134 } |
|
135 |
|
136 // --------------------------------------------------------------------------- |
|
137 // CJavaRegistryEntry::AttributeL |
|
138 // --------------------------------------------------------------------------- |
|
139 // |
|
140 EXPORT_C const MJavaAttribute* CJavaRegistryEntry::AttributeL( |
|
141 const TDesC& aName) const |
|
142 { |
|
143 JELOG2(EJavaStorage); |
|
144 return WritableEntry()->AttributeL(aName); |
|
145 } |
|
146 |
|
147 // --------------------------------------------------------------------------- |
|
148 // CJavaRegistryEntry::AttributesL |
|
149 // --------------------------------------------------------------------------- |
|
150 // |
|
151 EXPORT_C const RPointerArray<MJavaAttribute>& CJavaRegistryEntry |
|
152 ::AttributesL() const |
|
153 { |
|
154 JELOG2(EJavaStorage); |
|
155 return WritableEntry()->AttributesL(); |
|
156 } |