epoc32/include/cryptospi/cryptospistateapi.h
branchSymbian3
changeset 4 837f303aceeb
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/epoc32/include/cryptospi/cryptospistateapi.h	Wed Mar 31 12:33:34 2010 +0100
     1.3 @@ -0,0 +1,71 @@
     1.4 +/*
     1.5 +* Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 +* All rights reserved.
     1.7 +* This component and the accompanying materials are made available
     1.8 +* under the terms of the License "Eclipse Public License v1.0"
     1.9 +* which accompanies this distribution, and is available
    1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.11 +*
    1.12 +* Initial Contributors:
    1.13 +* Nokia Corporation - initial contribution.
    1.14 +*
    1.15 +* Contributors:
    1.16 +*
    1.17 +* Description: 
    1.18 +* crypto spi application interface
    1.19 +*
    1.20 +*/
    1.21 +
    1.22 +
    1.23 +/**
    1.24 + @file
    1.25 + @publishedAll
    1.26 + @released
    1.27 +*/
    1.28 +
    1.29 +#ifndef __CRYPTOAPI_CRYPTOSPISTATEAPI_H__
    1.30 +#define __CRYPTOAPI_CRYPTOSPISTATEAPI_H__
    1.31 +
    1.32 +#include <e32base.h>
    1.33 +
    1.34 +namespace CryptoSpi
    1.35 +	{
    1.36 +	class MPluginSelector;
    1.37 +	class CCharacteristicsAndPluginName;
    1.38 +
    1.39 +	/**
    1.40 +	The class provides the APIs to set and unset the rule-based selector.
    1.41 +	*/
    1.42 +	NONSHARABLE_CLASS(CCryptoSpiStateApi)
    1.43 +		{
    1.44 +	public:
    1.45 +
    1.46 +		/**
    1.47 +		Set the rule-based selector for the current thread. Once the rule-based 
    1.48 +		selector is set, it will be used by the crypto factory to select appropriate 
    1.49 +		plugin implementation. The owner of the selector is the user, and the ownership 
    1.50 +		is not transferd.
    1.51 +		
    1.52 +		@param aSelector The plugin selector to use
    1.53 +		*/
    1.54 +		IMPORT_C static void SetSelector(MPluginSelector* aSelector);
    1.55 +		
    1.56 +		/**
    1.57 +		The function unsets the selector for the current thread, so that
    1.58 +		the legacy selector will be used to select plugins. 
    1.59 +		*/
    1.60 +		IMPORT_C static void UnsetSelector();
    1.61 +		
    1.62 +		/**
    1.63 +		Enumerate the all characteristics in the system
    1.64 +		@param aCharacteristics the array of characteristic dll list.
    1.65 +		@param aInterface the uid of the interface, 0 means that enumerating characteristics for all the interfaces
    1.66 +		@param aExtended if extended characteristic needs to be retrieved.
    1.67 +		@leave ...	Any of the crypto error codes defined in 
    1.68 +  					cryptospi_errs.h or any of the system-wide error codes.	
    1.69 +		*/
    1.70 +		IMPORT_C static void EnumerateCharacteristicsL(RPointerArray<CCharacteristicsAndPluginName>& aCharacteristics, TInt32 aInterface, TBool aExtended);
    1.71 +		};
    1.72 +	}
    1.73 +	
    1.74 +#endif //__CRYPTOAPI_CRYPTOSPISTATEAPI_H__