sl@0: /* sl@0: * Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: * All rights reserved. sl@0: * This component and the accompanying materials are made available sl@0: * under the terms of the License "Eclipse Public License v1.0" sl@0: * which accompanies this distribution, and is available sl@0: * at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: * sl@0: * Initial Contributors: sl@0: * Nokia Corporation - initial contribution. sl@0: * sl@0: * Contributors: sl@0: * sl@0: * Description: sl@0: * characteristicsetup.cpp sl@0: * sl@0: */ sl@0: sl@0: sl@0: /** sl@0: @file sl@0: @internalComponent sl@0: */ sl@0: sl@0: #include sl@0: #include sl@0: #include "cryptopluginsloader.h" sl@0: sl@0: using namespace CryptoSpi; sl@0: sl@0: void CreatePropertiesL() sl@0: { sl@0: // sl@0: //Create plugin loader sl@0: // sl@0: CCryptoPluginsLoader* plugins=CCryptoPluginsLoader::NewLC(); sl@0: sl@0: // sl@0: //Create the plugin config property sl@0: // sl@0: plugins->CreatePluginConfigPropertyL(); sl@0: sl@0: // sl@0: //Create crypto interface property sl@0: // sl@0: TInt interfaceCount=sizeof(KInterfacesUids)/sizeof(KInterfacesUids[0]); sl@0: for (TInt i=0;iCreateInterfacePropertyL(KInterfacesUids[i].iUid); sl@0: } sl@0: sl@0: // sl@0: //Cleanup sl@0: // sl@0: CleanupStack::PopAndDestroy(plugins); sl@0: } sl@0: sl@0: /** sl@0: * @return KErrNone (0) if successful, KErrMemory if out of memory sl@0: * otherwise error result from calling RProperty::Define/Set sl@0: */ sl@0: TInt E32Main() sl@0: { sl@0: __UHEAP_MARK; sl@0: CTrapCleanup* trapCleanup=CTrapCleanup::New(); sl@0: if (!trapCleanup) sl@0: { sl@0: return KErrNoMemory; sl@0: } sl@0: sl@0: TRAPD(err, CreatePropertiesL()); sl@0: sl@0: delete trapCleanup; sl@0: __UHEAP_MARKEND; sl@0: return err; sl@0: } sl@0: sl@0: sl@0: sl@0: