os/security/cryptoservices/certificateandkeymgmt/tadditionalstores/tadditionalstoremapping.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 /*
     2 * Copyright (c) 1998-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 the License "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: 
    15 * FILECERTSTOREMAPPING.H
    16 * CFileCertStoreMapping class implementation
    17 *
    18 */
    19 
    20 
    21 /**
    22  @file 
    23  @internalTechnology
    24 */
    25  
    26 #ifndef __FILECERTSTOREMAPPING_H__
    27 #define __FILECERTSTOREMAPPING_H__
    28 
    29 #include <e32base.h>
    30 #include <s32std.h>
    31 #include <ct.h>
    32 #include <mctcertstore.h>
    33 
    34 /**
    35  * This class is used to associate an entry with the TStreamId of the stream
    36  * where the data of the certificate is stored.
    37  */
    38 class CFileCertStoreMapping : public CBase
    39 	{
    40 public:
    41 	static CFileCertStoreMapping* NewL();
    42 	static CFileCertStoreMapping* NewLC();
    43 	void ConstructL();
    44 	CFileCertStoreMapping();
    45 	~CFileCertStoreMapping();
    46 	/**
    47 	 * Sets the iEntry member. If there is already an entry, it is deleted.
    48 	 */
    49 	void SetEntry(CCTCertInfo* aCertInfo);
    50 	void SetId(TStreamId aId);
    51 	CCTCertInfo* Entry() const;
    52 	TStreamId Id() const;
    53 	void ExternalizeL(RWriteStream& aStream) const;
    54 	const RArray<TUid>& CertificateApps() const;
    55 	void SetCertificateApps(RArray<TUid>* aCertificateApps);
    56 	TBool IsApplicable(const TUid& aApplication) const;
    57 	TBool Trusted() const;
    58 	void SetTrusted(TBool aTrusted);
    59 	void SetTempRemoved(TBool aFlag);
    60 	TBool IsTempRemoved();
    61 
    62 private:
    63 	CCTCertInfo* iEntry;
    64 	RArray<TUid>* iCertificateApps;
    65 	TBool iTrusted;
    66 	/**
    67 	 * The id of the stream where the certificate data is stored.
    68 	 */
    69 	TStreamId iId;
    70 	TBool iTempRemoved;
    71 	};
    72 
    73 #endif