|
1 /* |
|
2 * Copyright (c) 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: The header file of DevandTruSrvCertStoreEntry |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef __DEVANDTRUSRVCERTSTOREENRY_H__ |
|
21 #define __DEVANDTRUSRVCERTSTOREENRY_H__ |
|
22 |
|
23 #include <e32base.h> |
|
24 #include <s32std.h> |
|
25 |
|
26 class CDevTokenCertInfo; |
|
27 |
|
28 /** |
|
29 * class CDevandTruSrvCertStoreEntry |
|
30 * |
|
31 * This class represents a cert in the store. It contains the cert info, the id |
|
32 * of the stream containing the certificate itself and its applications and |
|
33 * trust settings. |
|
34 * |
|
35 * @lib |
|
36 * @since S60 v3.2 |
|
37 */ |
|
38 class CDevandTruSrvCertStoreEntry : public CBase |
|
39 { |
|
40 public: |
|
41 |
|
42 // Create a new CDevTokenCertStoreEntry |
|
43 static CDevandTruSrvCertStoreEntry* NewL(const CDevTokenCertInfo& aEntry, |
|
44 RArray<TUid> aCertificateApps, |
|
45 TBool aTrusted, |
|
46 TStreamId aDataStreamId); |
|
47 |
|
48 // Read a CDevTokenCertStoreEntry from a stream. |
|
49 static CDevandTruSrvCertStoreEntry* NewLC(RReadStream& aStream); |
|
50 |
|
51 virtual ~CDevandTruSrvCertStoreEntry(); |
|
52 |
|
53 // Write a CDevTokenCertStoreEntry to a stream. |
|
54 void ExternalizeL(RWriteStream& aDataStream) const; |
|
55 |
|
56 // Accessors |
|
57 const CDevTokenCertInfo& CertInfo() const; |
|
58 |
|
59 TStreamId DataStreamId() const; |
|
60 |
|
61 const RArray<TUid>& CertificateApps() const; |
|
62 |
|
63 TBool IsApplicable(const TUid& aApplication) const; |
|
64 |
|
65 TBool Trusted() const; |
|
66 |
|
67 private: |
|
68 |
|
69 CDevandTruSrvCertStoreEntry(); |
|
70 |
|
71 void ConstructL(const CDevTokenCertInfo& aEntry, RArray<TUid> aCertificateApps, |
|
72 |
|
73 TBool aTrusted, TStreamId aDataStreamId); |
|
74 |
|
75 void InternalizeL(RReadStream& aStream); |
|
76 |
|
77 private: |
|
78 |
|
79 CDevTokenCertInfo* iCertInfo; |
|
80 |
|
81 RArray<TUid> iCertificateApps; |
|
82 |
|
83 TBool iTrusted; |
|
84 |
|
85 TStreamId iDataStreamId; |
|
86 }; |
|
87 |
|
88 #endif __DEVANDTRUSRVCERTSTOREENRY_H__ |
|
89 |
|
90 //EOF |
|
91 |