telephonyserverplugins/simatktsy/inc/CSatNotifySetUpMenu.h
changeset 0 3553901f7fa8
equal deleted inserted replaced
-1:000000000000 0:3553901f7fa8
       
     1 /*
       
     2 * Copyright (c) 2005-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        : CSatNotifySetUpMenu.h
       
    16 * Part of     : Common SIM ATK TSY / commonsimatktsy
       
    17 * Specific notifications class
       
    18 * Version     : 1.0
       
    19 *
       
    20 */
       
    21 
       
    22 
       
    23 
       
    24 #ifndef CSATNOTIFYSETUPMENU_H
       
    25 #define CSATNOTIFYSETUPMENU_H
       
    26 
       
    27 
       
    28 //  INCLUDES
       
    29 #include <etelsat.h>
       
    30 #include "MSatNotificationsBase.h"
       
    31 
       
    32 // FORWARD DECLARATIONS
       
    33 class CSatDataPackage;
       
    34 class CSatNotificationsTsy;
       
    35 
       
    36 /**
       
    37 * DESCRIPTION
       
    38 * SAT Setup Menu notification class.
       
    39 * Created when client requests to be notified when Setup Menu
       
    40 * command arrives from SIM.
       
    41 *
       
    42 * The SIM shall supply a set of menu items, which shall be used as
       
    43 * a main menu in SAT application. The user has then the opportunity
       
    44 * to choose one of these menu items at his own discretion.
       
    45 * Each item comprises a short identifier (used to indicate the selection)
       
    46 * and a text string. Also an Alpha identifier is supplied which acts as
       
    47 * a title for the list of menu items.
       
    48 * @lib Commonsimatktsy
       
    49 * @since 3.1
       
    50 */
       
    51 NONSHARABLE_CLASS ( CSatNotifySetUpMenu ) : public CBase,
       
    52                            public MSatNotificationsBase
       
    53     {
       
    54     public:   // Constructors and destructor
       
    55         
       
    56         /**
       
    57         * Two-phased constructor.
       
    58         * @param aNotificationsTsy: Pointer to NotificationsTsy
       
    59         * return CSatNotifySetUpMenu*: created object 
       
    60         */
       
    61         static CSatNotifySetUpMenu* NewL( 
       
    62         	CSatNotificationsTsy* aNotificationsTsy );
       
    63 
       
    64         /**
       
    65         * C++ Destructor.
       
    66         */
       
    67         ~CSatNotifySetUpMenu();
       
    68 
       
    69 	private:
       
    70         /**
       
    71         * By default C++ constructor is private.
       
    72         * @param aNotificationsTsy: Pointer to NotificationsTsy
       
    73         * @return None
       
    74         */
       
    75         CSatNotifySetUpMenu( CSatNotificationsTsy* aNotificationsTsy );
       
    76 
       
    77         /**
       
    78         * Class attributes are created in ConstructL. 
       
    79         * @param None
       
    80         * @return None
       
    81         */
       
    82         void ConstructL();
       
    83 
       
    84     public: // Functions from base classes
       
    85 
       
    86         /**
       
    87         * Set Up Menu Notification request received from client
       
    88         * @param aTsyReqHandle: request handle from ETel
       
    89         * @param aPackage: Packed data
       
    90         * @return KErrNone
       
    91         */
       
    92         TInt Notify( const TTsyReqHandle aTsyReqHandle,
       
    93             const TDataPackage& aPackage );
       
    94 
       
    95         /**
       
    96         * Cancels notification request for Set Up Menu.
       
    97         * @param aReqHandle notify request handle
       
    98         * @return KErrNone
       
    99         */
       
   100         TInt CancelNotification( const TTsyReqHandle aReqHandle );
       
   101                  
       
   102         /**
       
   103         * Completes Set Up Menu message to client
       
   104         * @param aDataPackage: Packaged return data
       
   105         * @param aErrorCode: Possible error code
       
   106         * @return KErrNone/ KErrCorrupt
       
   107         */
       
   108         TInt CompleteNotifyL( CSatDataPackage* aDataPackage, TInt aErrorCode );
       
   109 
       
   110 
       
   111         /**
       
   112         * From CSatNotificationsBase handles Set Up Menu terminal response 
       
   113         * coming from client.
       
   114         * @param aRsp: Response structure
       
   115         * @return KErrNone/ KErrCorrupt
       
   116         */
       
   117         TInt TerminalResponseL( TDes8* aRsp );
       
   118 
       
   119 	public: // New functions        
       
   120 	
       
   121         /**
       
   122         * Create notification specific terminal response data
       
   123         * @param aPCmdNumber: Proactive command number
       
   124         * @param aGeneralResult: Result of the proactive command
       
   125         * @param aAdditionalInfo: Additional info for terminal response
       
   126         * @return Success/Failure value
       
   127         */
       
   128         TInt CreateTerminalRespL( TUint8 aPCmdNumber, TUint8 aGeneralResult,
       
   129             					 const TDesC16& aAdditionalInfo );  
       
   130 
       
   131     private: // Data
       
   132 
       
   133         // Package received from ETel
       
   134         RSat::TSetUpMenuV2Pckg*     iSetUpMenuV2Pckg;
       
   135         // Toolkit name
       
   136         TBuf<RSat::KAlphaIdMaxSize> iToolKitName;
       
   137         // Pointer to the notifications tsy class
       
   138         CSatNotificationsTsy* iNotificationsTsy;
       
   139         // Flag for items next indicator    
       
   140         TBool iItemsNextIndicatorRemoved;
       
   141 
       
   142     };
       
   143 
       
   144 
       
   145 #endif // CSATNOTIFYSETUPMENU_H