diff -r 000000000000 -r 4e1aa6a622a0 sysstatemgmt/systemstatereferenceplugins/clayer/inc/ssmsecuritynotecontroller.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/sysstatemgmt/systemstatereferenceplugins/clayer/inc/ssmsecuritynotecontroller.h Tue Feb 02 00:53:00 2010 +0200 @@ -0,0 +1,141 @@ +/* +* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* Name : strtsecuritynotecontroller.h +* Part of : System Startup / StrtSecObs +* Declaration of CStrtSecurityNoteController class +* Version : %version: 1 % << Don't touch! Updated by Synergy at check-out. +* This material, including documentation and any related computer +* programs, is protected by copyright controlled by Nokia. All +* rights are reserved. Copying, including reproducing, storing, +* adapting or translating, any or all of this material requires the +* prior written consent of Nokia. This material also contains +* confidential information which may not be disclosed to others +* without the prior written consent of Nokia. +* Template version: 4.2 +* Nokia Core OS * +* File renamed from strtsecuritynotecontroller.h to ssmsecuritynotecontroller.h as part of Core OS transfer. +* +*/ + + + +#ifndef __SSMSECURITYNOTECONTROLLER_H__ +#define __SSMSECURITYNOTECONTROLLER_H__ + +#include + +#include "strtsecuritynotetype.h" + +/* + * @publishedPartner + * @released +*/ + +class CSsmSecurityCheckNotifier; +class CStrtSecNoteRequestQueue; + +/** + * This class controls security notes. + * + * lib : strtsecobs.lib + * @since S60 3.2 + * + */ +NONSHARABLE_CLASS( CStrtSecurityNoteController ) : public CActive + { + +public: + + /** + * Two-phased constructor. + */ + static CStrtSecurityNoteController* NewL(); + + /** + * Destructor. + */ + virtual ~CStrtSecurityNoteController(); + + /** + * Initiate a security code query or information note, if there is no note + * currently active. + * If there is an active note, put this note to queue. + * + * @param aNoteType Identifies the security note to show. + * @return One of the system-wide Symbian error codes. + */ + TInt SecurityNoteRequested( const TStrtSecurityNoteType aNoteType ); + + /** + * A security code has been verified. Remove it from the queue (if it is + * there). + * + * @param aNoteType Identifies the security code that has been verified. + */ + void SecurityCodeVerified( const TStrtSecurityNoteType aNoteType ); + +protected: +// from base class CActive + + /** + * From CActive. + * Implements cancellation of an outstanding request. + */ + virtual void DoCancel(); + + /** + * From CActive. + * Handles an active object's request completion event. + * Never leaves. + */ + virtual void RunL(); + +private: + + /** + * C++ default constructor. + */ + CStrtSecurityNoteController(); + + /** + * Second phase constructor. + */ + void ConstructL(); + + /** + * Jump to RunL. + */ + void CompleteSelf(); + +private: // data + + /** + * Queue of requested security notes. May not be NULL. + * Own. + */ + CStrtSecNoteRequestQueue* iQueue; + + /** + * Object for showing different security notes to user. May not be NULL. + * Own. + */ + CSsmSecurityCheckNotifier* iSecurityNote; + +#ifdef TEST_CLAYER_MACRO + friend class CLayerTestSsmEventObserver; +#endif //TEST_CLAYER_MACRO + + }; +#endif // __SSMSECURITYNOTECONTROLLER_H__