sysstatemgmt/systemstatereferenceplugins/clayer/inc/securitynotification.h
changeset 0 4e1aa6a622a0
child 5 1a73e8f1b64d
equal deleted inserted replaced
-1:000000000000 0:4e1aa6a622a0
       
     1 /*
       
     2 * Copyright (c) 2006-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 "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 * Name        : securitynotification.h
       
    16 * Part of     : System Startup / Starter
       
    17 * Interface   : Domain, Security Notification API
       
    18 * Parameter and constant definitions for launching
       
    19 * security-related notifications using the Notifier Framework.
       
    20 * Version     : %version: ou1s60rt#2.1.1 %
       
    21 * This material, including documentation and any related computer
       
    22 * programs, is protected by copyright controlled by Nokia.  All
       
    23 * rights are reserved.  Copying, including reproducing, storing,
       
    24 * adapting or translating, any or all of this material requires the
       
    25 * prior written consent of Nokia.  This material also contains
       
    26 * confidential information which may not be disclosed to others
       
    27 * without the prior written consent of Nokia.
       
    28 * Template version: 4.1
       
    29 * Nokia Core OS *
       
    30 *
       
    31 */
       
    32 
       
    33 
       
    34 
       
    35 #ifndef __SECURITYNOTIFICATION_H__
       
    36 #define __SECURITYNOTIFICATION_H__
       
    37 
       
    38 #include <e32cmn.h>
       
    39 
       
    40 /*
       
    41  * @file
       
    42 * @publishedPartner
       
    43 * @released
       
    44 */
       
    45 
       
    46 /** UID to use with Security Notifier communication. */
       
    47 static const TUid KSecurityNotifierUid = { 0x10005988 };
       
    48 
       
    49 /**
       
    50 * Parameters for requesting a security code query.
       
    51 *
       
    52 * Example:
       
    53 *   #include <etelmm.h>
       
    54 *   User::LeaveIfError( iNotifier.Connect() ); // iNotifier is an RNotifier member variable
       
    55 *   TSecurityNotificationPckg params;
       
    56 *   params().iStartup = EFalse;
       
    57 *   params().iEvent = RMobilePhone::EPin1Required;
       
    58 *   iNotifier.StartNotifierAndGetResponse( iStatus, KSecurityNotifierUid, params, iResult );
       
    59 *   SetActive();
       
    60 */
       
    61 class TSecurityNotification
       
    62     {
       
    63 public:
       
    64     /**
       
    65     * One of RMobilePhone::TMobilePhoneSecurityEvent enumeration values.
       
    66     * Identifies the code to request.
       
    67     */
       
    68     TInt iEvent;
       
    69 
       
    70     /**
       
    71     * Indicates whether the code is requested during system start-up or after it.
       
    72     * During system startup the code query dialogs will have no cancel button
       
    73     * and emergency call support is enabled.
       
    74     * After system startup the code query dialogs will have a cancel possibility.
       
    75     */
       
    76     TBool iStartup;
       
    77     };
       
    78 
       
    79 typedef TPckgBuf<TSecurityNotification> TSecurityNotificationPckg;
       
    80 
       
    81 /**
       
    82 * 'Old-style' parameters. To be used after system start-up phase.
       
    83 * The code query dialogs will have a cancel button and no emergency call support.
       
    84 *
       
    85 * Example:
       
    86 *   User::LeaveIfError( iNotifier.Connect() ); // iNotifier is an RNotifier member variable
       
    87 *   iNotifier.StartNotifierAndGetResponse( iStatus, KSecurityNotifierUid, KPin1Required, iResult );
       
    88 *   SetActive();
       
    89 */
       
    90 _LIT8( KPin1Required, "PINONE" );
       
    91 _LIT8( KPin2Required, "PINTWO" );
       
    92 _LIT8( KUPinRequired, "UPIN" );
       
    93 _LIT8( KPuk1Required, "PUKONE" );
       
    94 _LIT8( KPuk2Required, "PUKTWO" );
       
    95 _LIT8( KUPukRequired, "UPUK" );
       
    96 _LIT8( KNoSIMFound, "NOSIMFOUND" );
       
    97 _LIT8( KSimTerminated, "SIMTERMINATED" );
       
    98 _LIT8( KPassPhraseRequired, "SEC" );
       
    99 _LIT8( KAppPinRequired, "APPPINONE" );
       
   100 _LIT8( KSecondAppPinRequired, "APPPINTWO" );
       
   101 
       
   102 #endif // __SECURITYNOTIFICATION_H__