sysstatemgmt/systemstatereferenceplugins/clayer/inc/startupadaptationcommands.h
changeset 0 4e1aa6a622a0
child 5 1a73e8f1b64d
equal deleted inserted replaced
-1:000000000000 0:4e1aa6a622a0
       
     1 /*
       
     2 * Copyright (c) 2004-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        : startupadaptationcommands.h
       
    16 * Part of     : System Startup / Starter
       
    17 * Interface   : Domain, Startup Adaptation API
       
    18 * This header file defines the startup adaptation API commands
       
    19 * and their parameters.
       
    20 * This file contains the following sections:
       
    21 * - Command definitions
       
    22 * - Command parameter definitions
       
    23 * - Response parameter definitions
       
    24 * Version     : %version: ou1s60rt#12.1.4 %
       
    25 * This material, including documentation and any related computer
       
    26 * programs, is protected by copyright controlled by Nokia.  All
       
    27 * rights are reserved.  Copying, including reproducing, storing,
       
    28 * adapting or translating, any or all of this material requires the
       
    29 * prior written consent of Nokia.  This material also contains
       
    30 * confidential information which may not be disclosed to others
       
    31 * without the prior written consent of Nokia.
       
    32 * Template version: 4.0
       
    33 * Nokia Core OS *
       
    34 *
       
    35 */
       
    36 
       
    37 
       
    38 
       
    39 #ifndef __STARTUPADAPTATIONCOMMANDS_H__
       
    40 #define __STARTUPADAPTATIONCOMMANDS_H__
       
    41 
       
    42 #include <e32std.h>
       
    43 
       
    44 /*****************************************************
       
    45 *       Series 60 Customer
       
    46 *       Needs customer implementation
       
    47 *****************************************************/
       
    48 
       
    49 /**
       
    50 * All command and event definitions of Startup Adaptation API belong to
       
    51 * StartupAdaptation namespace.
       
    52 *
       
    53 * @file
       
    54 * @publishedPartner
       
    55 * @released
       
    56 *
       
    57 */
       
    58 namespace StartupAdaptation
       
    59     {
       
    60 
       
    61     /**
       
    62     * Command definitions
       
    63     * All commands contain a command id and a set of parameters. The command ids
       
    64     * are defined first and after that parameters for each command.
       
    65     *
       
    66     * This interface is asynchronous. A command is interpreted of being
       
    67     * completed after a response for that command is received.
       
    68     *
       
    69     * @param field means the parameter for the command.
       
    70     * @return field means the parameter for the response.
       
    71     */
       
    72     enum TCommand
       
    73         {
       
    74         /**
       
    75         * This command is used to change the global state of an S60 device.
       
    76         *
       
    77         * When changing the global state, S60 starter server issues a state
       
    78         * change command to startup adaptation via the startup adaptation API.
       
    79         * After receiving a response, S60 starter server will publish the new
       
    80         * state using Publish & Subscribe and execute operations required in
       
    81         * that state.
       
    82         *
       
    83         * @param  TGlobalStateChangePckg The requested global state.
       
    84         * @return TResponsePckg The success status of the state change.
       
    85         */
       
    86         EGlobalStateChange = 100,
       
    87 
       
    88         /**
       
    89         * Security state change request. Used only when global state is security
       
    90         * check.
       
    91         *
       
    92         * @param  TSecurityStateChangePckg The requested security state.
       
    93         * @return TSecurityStateResponsePckg The success status of the state
       
    94         * change and, if the operation was successful, additional information
       
    95         * which depends on the state.
       
    96         */
       
    97         ESecurityStateChange = 101,
       
    98 
       
    99         /**
       
   100         * Get global startup mode.
       
   101         *
       
   102         * The global startup mode indicates the mode in which the device has
       
   103         * been started. The startup mode can also be seen as a reason for the
       
   104         * startup.
       
   105         *
       
   106         * @param  None.
       
   107         * @return TGlobalStartupModeResponsePckg The success status of the
       
   108         * operation and, if the operation was successful, the global startup
       
   109         * mode.
       
   110         */
       
   111         EGetGlobalStartupMode = 102,
       
   112 
       
   113         /**
       
   114         * Request Domestic OS to perform self tests.
       
   115         *
       
   116         * Before launching any software components that are using some specific
       
   117         * hardware, self-tests need to be executed for the hardware. This
       
   118         * command is used to request licensee-specific self-tests to be
       
   119         * executed. It is allowed to perform the self-tests before this command,
       
   120         * but when this command is issued, S60 starter server expects to get the
       
   121         * result of the self-tests.
       
   122         *
       
   123         * @param  None.
       
   124         * @return TResponsePckg The success status of the self tests.
       
   125         */
       
   126         EExecuteSelftests = 103,
       
   127 
       
   128         /**
       
   129         * Get the language codes that are stored in the SIM card preferred
       
   130         * language lists.
       
   131         *
       
   132         * Primary language list will be queried first. Unless it contains
       
   133         * at least one language that can be taken into use, the secondary
       
   134         * preferred list will be queried for. Only if there is no acceptable
       
   135         * languages in the secondary list either, will the tertiary list be
       
   136         * queried for.
       
   137         *
       
   138         * @param  TLanguageListPriorityPckg.
       
   139         * @return TLanguageListResponsePckg The list of languages mapped to
       
   140         * Symbian language codes.
       
   141         */
       
   142         EGetSIMLanguages = 104,
       
   143 
       
   144         /**
       
   145         * This command is used to check the validity of Real Time Clock (RTC).
       
   146         *
       
   147         * @param  None.
       
   148         * @return TResponsePckg The success status of the operation. KErrNone
       
   149         * if the RTC time is valid, any other value indicates that it is not
       
   150         * valid.
       
   151         */
       
   152         EValidateRTCTime = 107,
       
   153 
       
   154         /**
       
   155         * Query whether the current SIM card is different from the previous one.
       
   156         *
       
   157         * The SIM changed status indicates whether the currently inserted SIM
       
   158         * card has changed since the last startup. This information can be used
       
   159         * for example to query whether the user wants to clear phone call logs.
       
   160         *
       
   161         * S60 starter server makes this query only if there is a SIM card
       
   162         * present. This command will only be issued in ESWStateCriticalPhaseOK
       
   163         * state.
       
   164         *
       
   165         * @param  None.
       
   166         * @return TBooleanResponsePckg Success status of the operation, and if
       
   167         * the operation was successful, indication whether the SIM card has been
       
   168         * changed after the last boot or not.
       
   169         */
       
   170         EGetSimChanged = 108, //This Enum should not be used.
       
   171 
       
   172         /**
       
   173         * Query whether the current SIM card is among the last used cards.
       
   174         *
       
   175         * It is up to the startup adaptation to decide the number of SIM cards
       
   176         * that are considered owned.
       
   177         *
       
   178         * If the SIM owned status is false, then the SIM changed status must be
       
   179         * true.
       
   180         *
       
   181         * S60 starter server makes this query only if there is a SIM card
       
   182         * present. This command will only be issued in ESWStateCriticalPhaseOK
       
   183         * state.
       
   184         *
       
   185         * @param  None.
       
   186         * @return TBooleanResponsePckg Success status of the operation, and if
       
   187         * the operation was successful, indication whether the SIM card is among
       
   188         * the five last used cards or not.
       
   189         */
       
   190         EGetSimOwned = 109,
       
   191 
       
   192         /**
       
   193         * This command is used to set a wake-up alarm time so that the device is
       
   194         * powered up by an alarm when it goes off, i.e. the device will be
       
   195         * started in the alarm mode.
       
   196         *
       
   197         * @see Command EGetGlobalStartupMode.
       
   198         *
       
   199         * @param  TWakeupAlarmPckg The time for the alarm.
       
   200         * @return TResponsePckg Success status of the operation.
       
   201         */
       
   202         ESetWakeupAlarm = 110,
       
   203 
       
   204         /**
       
   205         * This command is used to cancel a wake-up alarm.
       
   206         *
       
   207         * @param  None.
       
   208         * @return None Cancels must always succeed.
       
   209         */
       
   210         ECancelWakeupAlarm = 111,
       
   211 
       
   212         /**
       
   213         * A reboot request.
       
   214         *
       
   215         * This command is used to inform the startup adaptation that a reset
       
   216         * will be executed. The command also reports the reason for the reset
       
   217         * in case there is a need for some licensee-specific actions.
       
   218         *
       
   219         * This command will only be executed in the state ESWStateShuttingDown.
       
   220         * After receiving a response to the command, the S60 starter server will
       
   221         * only clean up itself and then call UserHal::SwitchOff().
       
   222         *
       
   223         * @param  TResetReasonPckg The reason for resetting.
       
   224         * @return TResponsePckg Success status of the operation.
       
   225         */
       
   226         EExecuteReset = 112,
       
   227 
       
   228         /**
       
   229         * A shutdown request.
       
   230         *
       
   231         * This command is used to inform the startup adaptation that the device
       
   232         * is going to be shut down.
       
   233         *
       
   234         * This command will only be executed in the state ESWStateShuttingDown.
       
   235         * After receiving a response to the command, the S60 starter server will
       
   236         * only clean up itself and then call UserHal::SwitchOff().
       
   237         *
       
   238         * @param  None.
       
   239         * @return TResponsePckg Success status of the operation.
       
   240         */
       
   241         EExecuteShutdown = 113,
       
   242 
       
   243         /**
       
   244         * Restore the factory settings of Domestic OS.
       
   245         *
       
   246         * Restoring factory settings may require some licensee-specific actions
       
   247         * to be performed. This command is used to request those actions to be
       
   248         * executed. The command will be issued during start-up sequence
       
   249         * following a reset caused by user-initiated RFS operation.
       
   250         *
       
   251         * @param  TRFSReasonPckg Indicates whether normal or deep RFS is
       
   252         * required.
       
   253         * @return TResponsePckg Success status of the operation.
       
   254         */
       
   255         EExecuteDOSRfs = 114,
       
   256 
       
   257         /**
       
   258         * Activate RF tranceiver for making an emergency call.
       
   259         *
       
   260         * Emergency calls have a high priority in S60 devices. Emergency calls
       
   261         * must be allowed whenever they are technically possible. There are two
       
   262         * cases, where the state of the device does not allow a mobile
       
   263         * originated call, but it must allow an emergency call.
       
   264         * - When the device is in offline mode. Applies also for the global
       
   265         *   state ESWStateEmergencyCallsOnly.
       
   266         * - When the device startup is in progress and RF transceiver is not
       
   267         *   yet switched on.
       
   268         * This command is used to switch RF transceiver on for making an
       
   269         * emergency call. As soon as the emergency call is finished, there will
       
   270         * be a command for switching RF transceiver off.
       
   271         *
       
   272         * @see Command EDeactivateRfAfterEmergencyCall.
       
   273         *
       
   274         * @param  None.
       
   275         * @return TResponsePckg Success status of the operation.
       
   276         */
       
   277         EActivateRfForEmergencyCall = 115,
       
   278 
       
   279         /**
       
   280         * Deactivate RF transceiver after making an emergency call.
       
   281         *
       
   282         * This command is used to switch RF transceiver off after an emergency
       
   283         * call.
       
   284         *
       
   285         * @see Command EActivateRfForEmergencyCall.
       
   286         *
       
   287         * @param  None.
       
   288         * @return TResponsePckg Success status of the operation.
       
   289         */
       
   290         EDeactivateRfAfterEmergencyCall = 116,
       
   291         
       
   292         /**
       
   293         * Query whether the current boot is a hidden reset.
       
   294         * Hidden reset means that boot-time queries and animations should not
       
   295         * be shown to the user.
       
   296         *
       
   297         * Boot-time queries and animations will be hidden from the user if the
       
   298         * system is executing a controlled reset (EExecuteReset command) or
       
   299         * this query returns ETrue.
       
   300         *
       
   301         * This query should return ETrue if the ongoing boot is caused by SW
       
   302         * reset (either controlled, initiated by EExecuteReset command, or
       
   303         * uncontrolled, caused by critical SW failure).
       
   304         * This query should return EFalse if the ongoing boot is initiated by
       
   305         * any other means (such as user pressing the power key or a wakeup
       
   306         * alarm occurring).
       
   307         *
       
   308         * This command will always be issued in ESWStateStartingUiServices
       
   309         * state.
       
   310         */
       
   311         EGetHiddenReset = 117
       
   312 
       
   313         };
       
   314 
       
   315     /*
       
   316     * ==========================================================================
       
   317     * Command parameter definitions
       
   318     * ==========================================================================
       
   319     */
       
   320 
       
   321     /**
       
   322     * Parameter definition for EGlobalStateChange.
       
   323      * Parameter indicates the global state to move to.
       
   324     *
       
   325     * Possible state transitions are:
       
   326     * ESWStateStartingUiServices -> ESWStateStartingCriticalApps
       
   327     * ESWStateStartingCriticalApps -> ESWStateSelfTestOK
       
   328     * ESWStateSelfTestOK -> ESWStateSecurityCheck
       
   329     * ESWStateSelfTestOK -> ESWStateCharging
       
   330     * ESWStateSelfTestOK -> ESWStateAlarm
       
   331     * ESWStateSelfTestOK -> ESWStateTest
       
   332     * ESWStateSecurityCheck -> ESWStateCriticalPhaseOK
       
   333     * ESWStateSecurityCheck -> ESWStateEmergencyCallsOnly
       
   334     * ESWStateCriticalPhaseOK -> ESWStateNormalRfOn
       
   335     * ESWStateCriticalPhaseOK -> ESWStateNormalRfOff
       
   336     * ESWStateNormalRfOn -> ESWStateNormalRfOff
       
   337     * ESWStateNormalRfOn -> ESWStateNormalBTSap
       
   338     * ESWStateNormalRfOff -> ESWStateNormalRfOn
       
   339     * ESWStateNormalRfOff -> ESWStateNormalBTSap
       
   340     * ESWStateNormalBTSap -> ESWStateNormalRfOn
       
   341     * ESWStateNormalBTSap -> ESWStateNormalRfOff
       
   342     * ESWStateCharging -> ESWStateChargingToAlarm
       
   343     * ESWStateCharging -> ESWStateChargingToNormal
       
   344     * ESWStateAlarm -> ESWStateAlarmToCharging
       
   345     * ESWStateAlarm -> ESWStateAlarmToNormal
       
   346     * ESWStateChargingToAlarm -> ESWStateAlarm
       
   347     * ESWStateAlarmToCharging -> ESWStateCharging
       
   348     * ESWStateChargingToNormal -> ESWStateSecurityCheck
       
   349     * ESWStateAlarmToNormal -> ESWStateSecurityCheck
       
   350     * (Any state except ESWStateStartingUiServices, ESWStateTest,
       
   351     *  ESWStateFatalStartupError and ESWStateShuttingDown) -> ESWStateFatalStartupError
       
   352     * (Any state except ESWStateTest and ESWStateShuttingDown) -> ESWStateShuttingDown
       
   353     */
       
   354     enum TGlobalState
       
   355         {
       
   356         ESWStateStartingUiServices = 100,
       
   357         ESWStateStartingCriticalApps,
       
   358         ESWStateSelfTestOK,
       
   359 
       
   360         // States for the security check phase.
       
   361         ESWStateSecurityCheck,
       
   362         ESWStateCriticalPhaseOK,
       
   363         ESWStateEmergencyCallsOnly,
       
   364 
       
   365         // Terminal states defined by the boot mode (and some other variables such as offline mode).
       
   366         ESWStateTest,
       
   367         ESWStateCharging,
       
   368         ESWStateAlarm,
       
   369         ESWStateNormalRfOn,
       
   370         ESWStateNormalRfOff,
       
   371         ESWStateNormalBTSap,
       
   372 
       
   373         // States for notifying adaptation about a terminal state change.
       
   374         ESWStateAlarmToCharging,
       
   375         ESWStateChargingToAlarm,
       
   376         ESWStateChargingToNormal,
       
   377         ESWStateAlarmToNormal,
       
   378 
       
   379         // Shutdown-related states.
       
   380         ESWStateShuttingDown,
       
   381 
       
   382         // Error states.
       
   383         ESWStateFatalStartupError
       
   384         };
       
   385 
       
   386     /**
       
   387     * Buffer descriptor containing TGlobalState object.
       
   388     */
       
   389     typedef TPckgBuf<TGlobalState> TGlobalStateChangePckg;
       
   390 
       
   391     /**
       
   392     * Parameter definition for ESecurityStateChange.
       
   393     * Parameter indicates the security state to move to.
       
   394     *
       
   395     * Possible state transitions are:
       
   396     * ESIMPresent -> ESIMReadable
       
   397     * ESIMPresent -> ESIMLessOfflineSupported
       
   398     * ESIMReadable -> ESIMInvalid
       
   399     * ESIMInvalid -> ESecurityCheckFailed
       
   400     * ESIMInvalid -> ESIMRejected
       
   401     * ESIMRejected -> ESIMBlocked
       
   402     * ESIMRejected -> ESecurityCheckFailed
       
   403     * ESIMBlocked -> EPINRequired
       
   404     * ESIMBlocked -> EAskPUK
       
   405     * EPINRequired -> EAskPIN
       
   406     * EPINRequired -> ESIMCodesOK
       
   407     * EAskPIN -> EAskPUK
       
   408     * EAskPIN -> ESIMCodesOK
       
   409     * EAskPUK -> ESIMCodesOK
       
   410     * EAskPUK -> ESecurityCheckFailed
       
   411     * ESIMCodesOK -> ESIMLock
       
   412     * ESIMCodesOK -> ESECCodeRequired
       
   413     * ESIMLock -> ESecurityCheckOK
       
   414     * ESIMLock -> ESecurityCheckFailed
       
   415     * ESIMLessOfflineSupported -> ESIMLock
       
   416     * ESIMLessOfflineSupported -> ESECCodeRequired
       
   417     * ESIMLessOfflineSupported -> ESecurityCheckFailed
       
   418     * ESECCodeRequired -> EAskSEC
       
   419     * ESECCodeRequired -> ESECCodeOK
       
   420     * EAskSEC -> ESECBlocked
       
   421     * EAskSEC -> ESECCodeOK
       
   422     * ESECBlocked -> EAskSEC
       
   423     * ESECCodeOK -> ESIMLock
       
   424     */
       
   425     enum TSecurityState
       
   426         {
       
   427         ESIMPresent = 100,       ///< Response param: Yes/No
       
   428         ESIMReadable,            ///< Response param: None (wait until SIM readable)
       
   429         ESIMRejected,            ///< Response param: Yes/No
       
   430         ESIMBlocked,             ///< Response param: No/PUK1/UPUK
       
   431         EPINRequired,            ///< Response param: No/PIN1/UPIN
       
   432         ESECCodeRequired,        ///< Response param: No/SEC/Master
       
   433 
       
   434         ESIMLessOfflineSupported,///< Response param: None (inform adaptation only)
       
   435         ESIMLock,                ///< Response param: SimLockRestricted/SimLockRestrictionOn/
       
   436                                  ///< SimLockRestrictionPending/SimLockOk
       
   437         ESECBlocked,             ///< Response param: None (inform adaptation only)
       
   438 
       
   439         EAskPIN,                 ///< Response param: None (inform adaptation only)
       
   440         EAskPUK,                 ///< Response param: None (inform adaptation only)
       
   441         EAskSEC,                 ///< Response param: None (inform adaptation only)
       
   442         ESIMCodesOK,             ///< Response param: None (inform adaptation only)
       
   443         ESECCodeOK,              ///< Response param: None (inform adaptation only)
       
   444         ESecurityCheckOK,        ///< Response param: None (inform adaptation only)
       
   445         ESecurityCheckFailed,     ///< Response param: None (inform adaptation only)
       
   446         ESIMInvalid              ///< Response param: Yes/No
       
   447         };
       
   448 
       
   449     /**
       
   450     * Buffer descriptor containing TSecurityState object.
       
   451     */
       
   452     typedef TPckgBuf<TSecurityState> TSecurityStateChangePckg;
       
   453 
       
   454 
       
   455     /**
       
   456     * Parameter definition for EGetSIMLanguages.
       
   457     */
       
   458     enum TLanguageListPriority
       
   459         {
       
   460         /**
       
   461         * Return list of language codes based on the most preferred language
       
   462         * list. In GSM the most preferred language list is stored in EF_LI
       
   463         * (see 3GPP TS 31.102).
       
   464         */
       
   465         EPrimaryLanguages = 100,
       
   466         /**
       
   467         * Return list of language codes based on the second preferred language
       
   468         * list. In GSM the second preferred language list is stored in EF_PL
       
   469         * (see 3GPP TS 51.011).
       
   470         */
       
   471         ESecondaryLanguages,
       
   472         /**
       
   473         * Return list of language codes based on the third preferred language
       
   474         * list. In GSM the third preferred language list is stored in EF_LP
       
   475         * (see 3GPP TS 51.011).
       
   476         */
       
   477         ETertiaryLanguages,
       
   478         };
       
   479 
       
   480     /**
       
   481     * Buffer descriptor containing TLanguageListPriority object.
       
   482     */
       
   483     typedef TPckgBuf<TLanguageListPriority> TLanguageListPriorityPckg;
       
   484 
       
   485     /**
       
   486     * Parameter definition for ESetWakeupAlarm and ECancelWakeupAlarm.
       
   487     */
       
   488     NONSHARABLE_STRUCT( TWakeupAlarmTime )
       
   489         {
       
   490         /**
       
   491         * The local time for the alarm. Startup adaptation needs to take the
       
   492         * offsets into account.
       
   493         */
       
   494         TTime iTime;
       
   495         /**
       
   496         * Universal time offset in seconds.
       
   497         */
       
   498         TTimeIntervalSeconds iUniversalTimeOffset;
       
   499         /**
       
   500         * Daylight saving offset in seconds, if not taken into account by the
       
   501         * universal time offset parameter.
       
   502         */
       
   503         TTimeIntervalSeconds iDaylightSavingOffset;
       
   504         };
       
   505 
       
   506     /**
       
   507     * Buffer descriptor containing TWakeupAlarmTime object.
       
   508     */
       
   509     typedef TPckgBuf<TWakeupAlarmTime> TWakeupAlarmPckg;
       
   510 
       
   511     /**
       
   512     * Parameter definition for EExecuteReset.
       
   513     */
       
   514     enum TResetReason
       
   515         {
       
   516         /** A reset due to display language switch. */
       
   517         ELanguageSwitchReset = 100,
       
   518         /** A reset due to restoring factory settings. */
       
   519         ENormalRFSReset = 101,
       
   520         /** A reset due to restoring factory settings (deep). */
       
   521         EDeepRFSReset = 102,
       
   522         /** A reset due to firmware update. */
       
   523         EFirmwareUpdate = 104,
       
   524         /** A reset due to an error. */
       
   525         EUnknownReset = 105,
       
   526         /** A reset due to removing operator settings. */
       
   527         EOperatorSettingReset = 106,
       
   528         /** A reset due to network mode change. */
       
   529         ENetworkModeChangeReset = 107,
       
   530         /** A reset due removing/inserting SIM card. */
       
   531         ESIMStatusChangeReset = 108,
       
   532         EDRMReset = 109,
       
   533         /** A reset after restoring backed-up data. */
       
   534         EDataRestoreReset = 110,
       
   535         /** A reset required by Field Test software. */
       
   536         EFieldTestReset = 111
       
   537         };
       
   538 
       
   539     /**
       
   540     * Buffer descriptor containing TResetReason object.
       
   541     */
       
   542     typedef TPckgBuf<TResetReason> TResetReasonPckg;
       
   543 
       
   544 
       
   545     /**
       
   546     * Parameter definition for EExecuteDOSRfs.
       
   547     */
       
   548     enum TRFSReason
       
   549         {
       
   550         ENormalRFS = 100,
       
   551         EDeepRFS
       
   552         };
       
   553 
       
   554     /**
       
   555     * Buffer descriptor containing TRFSReason object.
       
   556     */
       
   557     typedef TPckgBuf<TRFSReason> TRFSReasonPckg;
       
   558 
       
   559     /*
       
   560     * ==========================================================================
       
   561     * Response parameter definitions
       
   562     * ==========================================================================
       
   563     */
       
   564 
       
   565     /**
       
   566     * Parameter definition for command responses that need only success or
       
   567     * failure information.
       
   568     */
       
   569     typedef TPckgBuf<TInt> TResponsePckg;
       
   570 
       
   571 
       
   572     /**
       
   573     * Parameter definition for ESecurityStateChange command response.
       
   574     */
       
   575     enum TSecurityStateInfo
       
   576         {
       
   577         EYes = 100,
       
   578         ENo,
       
   579 
       
   580         EPUK1Required,              // Only for SIMBlocked
       
   581         EUPUKRequired,              // Only for SIMBlocked
       
   582 
       
   583         EPIN1Required,              // Only for PINRequired
       
   584         EUPINRequired,              // Only for PINRequired
       
   585 
       
   586         ESecurityCodeRequired,      // Only for SECCodeRequired
       
   587         EMasterCodeRequired,        // Only for SECCodeRequired
       
   588 
       
   589         ESimLockRestricted,         // Only for SIMLock
       
   590         ESimLockRestrictionOn,      // Only for SIMLock
       
   591         ESimLockRestrictionPending, // Only for SIMLock
       
   592         ESimLockOk,                 // Only for SIMLock
       
   593 
       
   594         ENoValue                    // For SIMReadable, SIMLessOfflineSupported,
       
   595                                     // SECBlocked, AskPIN, AskPUK, AskSEC,
       
   596                                     // SIMCodesOK, SECCodeOK,
       
   597                                     // SecurityCheckOK, SecurityCheckFailed
       
   598         };
       
   599 
       
   600     /**
       
   601     * Parameter definition for ESecurityStateChange command response.
       
   602     */
       
   603     NONSHARABLE_STRUCT( TSecurityStateResponse )
       
   604         {
       
   605         /**
       
   606         * Indicates whether operation was successful or if not, the reason why.
       
   607         */
       
   608         TInt iErrorCode;
       
   609         /**
       
   610         * Response value. Valid only if iErrorCode is KErrNone.
       
   611         */
       
   612         TSecurityStateInfo iValue;
       
   613         };
       
   614 
       
   615     /**
       
   616     * Buffer descriptor containing TSecurityStateResponse object.
       
   617     */
       
   618     typedef TPckgBuf<TSecurityStateResponse> TSecurityStateResponsePckg;
       
   619 
       
   620 
       
   621     /**
       
   622     * Parameter definition for EGetGlobalStartupMode command response.
       
   623     */
       
   624     enum TGlobalStartupMode
       
   625         {
       
   626         ENormal = 100,
       
   627         EAlarm,
       
   628         ECharging,
       
   629         ETest
       
   630         };
       
   631 
       
   632     /**
       
   633     * Parameter definition for EGetGlobalStartupMode command response.
       
   634     */
       
   635     struct TGlobalStartupModeResponse
       
   636         {
       
   637         /**
       
   638         * Indicates whether operation was successful or if not, the reason why.
       
   639         */
       
   640         TInt iErrorCode;
       
   641         /**
       
   642         * Response value. Valid only if iErrorCode is KErrNone.
       
   643         */
       
   644         TGlobalStartupMode iValue;
       
   645         };
       
   646 
       
   647     /**
       
   648     * Buffer descriptor containing TGlobalStartupModeResponse object.
       
   649     */
       
   650     typedef TPckgBuf<TGlobalStartupModeResponse> TGlobalStartupModeResponsePckg;
       
   651 
       
   652 
       
   653     /**
       
   654     * Enumeration of preferred languages for EGetSIMLanguages command response.
       
   655     *
       
   656     * Implementation should map each entry in the physical list stored in
       
   657     * SIM card to a corresponding S60 preferred language code (one of the values
       
   658     * of TPreferredLanguage enumerations).
       
   659     * Implementation may skip the entries for which there is no corresponding
       
   660     * value in the TPreferredLanguage enumeration.
       
   661     */
       
   662 
       
   663     enum TPreferredLanguage
       
   664         {                         // ISO 639 GSM 0338
       
   665         EPrefLangEnglish = 1,     // EN      1
       
   666         EPrefLangFrench = 2,      // FR      3
       
   667         EPrefLangGerman = 3,      // DE      0
       
   668         EPrefLangSpanish = 4,     // ES      4
       
   669         EPrefLangItalian = 5,     // IT      2
       
   670         EPrefLangSwedish = 6,     // SV      6
       
   671         EPrefLangDanish = 7,      // DA      7
       
   672         EPrefLangNorwegian = 8,   // NO      10
       
   673         EPrefLangFinnish = 9,     // FI      9
       
   674         EPrefLangPortuguese = 13, // PT      8
       
   675         EPrefLangTurkish = 14,    // TR      12
       
   676         EPrefLangIcelandic = 15,  // IS      36
       
   677         EPrefLangRussian = 16,    // RU      35
       
   678         EPrefLangHungarian = 17,  // HU      13
       
   679         EPrefLangDutch = 18,      // NL      5
       
   680         EPrefLangCzech = 25,      // CS      32
       
   681         EPrefLangSlovak = 26,     // SK
       
   682         EPrefLangPolish = 27,     // PL      14
       
   683         EPrefLangSlovenian = 28,  // SL
       
   684         EPrefLangPrcChinese = 31, // ZH
       
   685         EPrefLangJapanese = 32,   // JA
       
   686         EPrefLangThai = 33,       // TH
       
   687         EPrefLangArabic = 37,     // AR      34
       
   688         EPrefLangTagalog = 39,    // TL
       
   689         EPrefLangBulgarian = 42,  // BG
       
   690         EPrefLangCatalan = 44,    // CA
       
   691         EPrefLangCroatian = 45,   // HR
       
   692         EPrefLangEstonian = 49,   // ET
       
   693         EPrefLangFarsi = 50,      // FA
       
   694         EPrefLangGreek = 54,      // EL      11
       
   695         EPrefLangHebrew = 57,     // IW      33
       
   696         EPrefLangHindi = 58,      // HI
       
   697         EPrefLangIndonesian = 59, // IN
       
   698         EPrefLangKorean = 65,     // KO
       
   699         EPrefLangLatvian = 67,    // LV
       
   700         EPrefLangLithuanian = 68, // LT
       
   701         EPrefLangMalay = 70,      // MS
       
   702         EPrefLangMarathi = 72,    // MR
       
   703         EPrefLangRomanian = 78,   // RO
       
   704         EPrefLangSerbian = 79,    // SR
       
   705         EPrefLangUkrainian = 93,  // UK
       
   706         EPrefLangUrdu = 94,       // UR
       
   707         EPrefLangVietnamese = 96, // VI
       
   708         EPrefLangBasque = 102,    // EU
       
   709         EPrefLangGalician = 103   // GL
       
   710         };
       
   711 
       
   712 
       
   713     /**
       
   714     * Array of preferred languages for EGetSIMLanguages command response.
       
   715     */
       
   716     typedef RArray<TPreferredLanguage> RLanguageList;
       
   717 
       
   718 
       
   719     /**
       
   720     * Parameter definition for EGetSIMLanguages command response.
       
   721     */
       
   722     NONSHARABLE_CLASS( RLanguageListResponse )
       
   723         {
       
   724     private:
       
   725         RLanguageListResponse( const RLanguageListResponse& );
       
   726         RLanguageListResponse& operator= ( const RLanguageListResponse& );
       
   727 
       
   728     public:
       
   729 
       
   730         /**
       
   731         * Constructor.
       
   732         */
       
   733         inline RLanguageListResponse();
       
   734 
       
   735         /**
       
   736         * Closes the language code array and frees all memory allocated to the
       
   737         * array.
       
   738         *
       
   739         * The function must be called before this object is destroyed.
       
   740         */
       
   741         inline void Close();
       
   742 
       
   743         /**
       
   744         * Use KErrNotFound to indicate that there is no SIM card present or the
       
   745         * SIM card does not contain the requested list.
       
   746         */
       
   747         TInt iErrorCode;
       
   748 
       
   749         /**
       
   750         * Array of zero or more languages codes.
       
   751         */
       
   752         RLanguageList iLanguages;
       
   753         };
       
   754 
       
   755     /**
       
   756     * Pointer descriptor representing an RLanguageListResponse object.
       
   757     */
       
   758     typedef TPckg<RLanguageListResponse> TLanguageListResponsePckg;
       
   759 
       
   760 
       
   761     /**
       
   762     * Parameter definition for command responses that need success or failure
       
   763     * information and a boolean return value.
       
   764     */
       
   765     struct TBooleanResponse
       
   766         {
       
   767         /**
       
   768         * Indicates whether operation was successful or if not, the reason why.
       
   769         */
       
   770         TInt iErrorCode;
       
   771         /**
       
   772         * Response value. Valid only if iErrorCode is KErrNone.
       
   773         */
       
   774         TBool iValue;
       
   775         };
       
   776 
       
   777     /**
       
   778     * Buffer descriptor containing TBooleanResponse object.
       
   779     */
       
   780     typedef TPckgBuf<TBooleanResponse> TBooleanResponsePckg;
       
   781 
       
   782     }
       
   783 
       
   784 #include <ssm/startupadaptationcommands.inl>
       
   785 
       
   786 #endif // __STARTUPADAPTATIONCOMMANDS_H__