adaptationlayer/tsy/nokiatsy_dll/inc/cmmphonemesshandler.h
changeset 5 8ccc39f9d787
parent 0 63b37f68c1ce
child 8 6295dc2169f3
equal deleted inserted replaced
4:510c70acdbf6 5:8ccc39f9d787
     9 * Initial Contributors:
     9 * Initial Contributors:
    10 * Nokia Corporation - initial contribution.
    10 * Nokia Corporation - initial contribution.
    11 *
    11 *
    12 * Contributors:
    12 * Contributors:
    13 *
    13 *
    14 * Description: 
    14 * Description:
    15 *
    15 *
    16 */
    16 */
    17 
    17 
    18 
    18 
    19 
    19 
    29 
    29 
    30 #include "mmmmesshandlerbase.h"
    30 #include "mmmmesshandlerbase.h"
    31 #include "cmmphonetreceiver.h"
    31 #include "cmmphonetreceiver.h"
    32 #include "nokiatsy_internal_variation.h"
    32 #include "nokiatsy_internal_variation.h"
    33 #include "muiccoperationbase.h"
    33 #include "muiccoperationbase.h"
       
    34 #include "cmmuiccmesshandler.h"
    34 
    35 
    35 // CONSTANTS
    36 // CONSTANTS
    36     //None
    37     //None
    37 
    38 
    38 // MACROS
    39 // MACROS
   123         * @return KErrNone or error code
   124         * @return KErrNone or error code
   124         */
   125         */
   125         TInt ProcessUiccMsg(
   126         TInt ProcessUiccMsg(
   126             TInt aTraId,
   127             TInt aTraId,
   127             TInt aStatus,
   128             TInt aStatus,
   128             const TDesC8& aFileData );
   129             TUint8 aDetails,
       
   130             const TDesC8& aFileData );
       
   131 
       
   132         /**
       
   133         * Checks if "Refresh Done" will be sent to UICC
       
   134         * @param TInt aError : Error value during re-reading
       
   135         */
       
   136         void SmsCachingCompleted( TInt aError );
       
   137 
       
   138         /**
       
   139         * Checks if "Refresh Done" will be sent to UICC
       
   140         * @param TInt aError : Error value during re-reading
       
   141         */
       
   142         void ServiceTableCachingCompleted( TInt aError );
       
   143 
       
   144         /**
       
   145         * Checks if "Refresh Done" will be sent to UICC
       
   146         * @param TUint aError : Error value during re-reading
       
   147         */
       
   148         void CallForwFlagsCachingCompleted( TUint aError );
       
   149 
       
   150         /**
       
   151         * Checks if "Refresh Done" will be sent to UICC
       
   152         * @param aError : Error value during re-reading
       
   153         * @return refresh ongoing, True or False.
       
   154         */
       
   155         TBool OplRulesCachingCompleted( TInt aError );
       
   156 
       
   157         /**
       
   158         * Checks if "Refresh Done" will be sent to UICC
       
   159         * @param aError : Error value during re-reading
       
   160         */
       
   161         void PnnRecordCachingCompleted( TUint8 aError );
       
   162 
       
   163         /**
       
   164         * Checks if "Refresh Done" will be sent to UICC
       
   165         * @param aError : Error value during re-reading
       
   166         */
       
   167         void OnsNameCachingCompleted( TUint8 aError );
   129 
   168 
   130     protected:
   169     protected:
   131 
   170 
   132         /**
   171         /**
   133         * Default constructor.
   172         * Default constructor.
   191         * @param CMmMessageRouter* aMessageRouter: pointer to message
   230         * @param CMmMessageRouter* aMessageRouter: pointer to message
   192         *  router object
   231         *  router object
   193         * @return void : None
   232         * @return void : None
   194         */
   233         */
   195         void ConstructL( CMmMessageRouter* aMessageRouter );
   234         void ConstructL( CMmMessageRouter* aMessageRouter );
       
   235 
       
   236         /**
       
   237         * Read request for EFest
       
   238         * @return KErrNone or error code
       
   239         */
       
   240         TInt UiccReadEfEstReq();
       
   241 
       
   242         /**
       
   243         * Handles response for EFest reading in case of getting
       
   244         * ACL status       
       
   245         * @param aStatus status of the operation
       
   246         * @param aFileData content of the EFest
       
   247         * @return none
       
   248         */
       
   249         void UiccGetAclStatusReadEfEstResp( 
       
   250             TInt aStatus, 
       
   251             const TDesC8& aFileData );
       
   252 
       
   253         /**
       
   254         * Handles response for EFest reading in case of setting
       
   255         * ACL status       
       
   256         * @param aStatus status of the operation
       
   257         * @param aFileData content of the EFest
       
   258         * @return none
       
   259         */
       
   260         void UiccSetAclStatusReadEfEstResp( 
       
   261             TInt aStatus, 
       
   262             const TDesC8& aFileData );
       
   263 
       
   264         /**
       
   265         * Write request for EFest
       
   266         * @param aOldAclState old ACL state
       
   267         * @return KErrNone or error code
       
   268         */
       
   269         TInt UiccSetAclStatusWriteEfEstReq( TUint8 aOldAclState );
       
   270 
       
   271         /**
       
   272         * Handles response for EFest writing in case of setting
       
   273         * ACL status       
       
   274         * @param aStatus status of the operation
       
   275         * @return none
       
   276         */
       
   277         void UiccSetAclStatusWriteEfEstResp(
       
   278             TInt aStatus );
       
   279 
       
   280         /**
       
   281         * Read request for EFacl
       
   282         * @return KErrNone or error code
       
   283         */
       
   284         TInt UiccReadAclReq();
       
   285 
       
   286         /**
       
   287         * Handles response for EFacl reading 
       
   288         * @param aStatus status of the operation
       
   289         * @param aFileData content of the EFacl
       
   290         * @return none
       
   291         */
       
   292         void UiccReadAclResp(
       
   293             TInt aStatus, 
       
   294             const TDesC8& aFileData );
       
   295 
       
   296         /**
       
   297         * Encrypt from ACL to CDesC8ArrayFlat.
       
   298         * @param const TDesC8& aTlv
       
   299         * @param TInt aTotalEntries
       
   300         * @return CDesC8ArrayFlat*
       
   301         */
       
   302         CDesC8ArrayFlat* DecodeACL(
       
   303             const TDesC8& aTlv,
       
   304             TInt aTotalEntries) const;
       
   305 
       
   306         /**
       
   307         * Sends number of ACL index to the client.
       
   308         * @return none
       
   309         */
       
   310         void CompleteEnumerateAPNEntries();
       
   311 
       
   312         /**
       
   313         * Completes APN entry reading
       
   314         * @param TUint8 aIndex
       
   315         * @return none
       
   316         */
       
   317         void CompleteGetAPNName( TUint8 aIndex );
       
   318 
       
   319         /**
       
   320         * Deletes APN entry from internal cache and writes
       
   321         * the change to EFacl
       
   322         * @param TUint8 aIndex index to be deleted
       
   323         * @return KErrNone or error code
       
   324         */
       
   325         TInt UiccDeleteApnEntry( TInt aIndex );
       
   326 
       
   327         /**
       
   328         * Writes APN entries from internal cache to the EFAcl
       
   329         * @param TUint8 aIndex index to be deleted
       
   330         * @return KErrNone or error code
       
   331         */
       
   332         TInt UiccWriteEfAclReq();
       
   333 
       
   334         /**
       
   335         * Handles response for EFAcl writing
       
   336         * @param aStatus status of the operation
       
   337         * @return none
       
   338         */
       
   339         void UiccWriteEfAclResp( TInt aStatus );
       
   340 
       
   341         /**
       
   342         * Calculate total length of ACL.
       
   343         * @param CDesC8ArrayFlat* aApnList
       
   344         * @return TUint16 Total legtn of ACL.
       
   345         */
       
   346         TUint16 ACLLength( CDesC8ArrayFlat* aApnList ) const;
   196 
   347 
   197     private:
   348     private:
   198 
   349 
   199         /**
   350         /**
   200         * For nokiatsy internal refresh handling
   351         * For nokiatsy internal refresh handling
   203             {
   354             {
   204             KRefreshSms = 0x01,
   355             KRefreshSms = 0x01,
   205             KRefreshCallForwardingFlags = 0x02,
   356             KRefreshCallForwardingFlags = 0x02,
   206             KRefreshOplRules = 0x04,
   357             KRefreshOplRules = 0x04,
   207             KRefreshPnnRecord = 0x08,
   358             KRefreshPnnRecord = 0x08,
   208             KRefreshOnsName = 0x10
   359             KRefreshOnsName = 0x10,
       
   360             KRefreshServiceTable = 0x20
   209             };
   361             };
   210 
   362 
   211         /**
   363         /**
   212         * Read IMSI from UICC
   364         * Read IMSI from UICC
   213         * @return Error code
   365         * @return Error code
   268          */
   420          */
   269         void UiccProcessSpnNameInfo(
   421         void UiccProcessSpnNameInfo(
   270             TInt aStatus,
   422             TInt aStatus,
   271             const TDesC8& aFileData );
   423             const TDesC8& aFileData );
   272 
   424 
       
   425         /**
       
   426          * Handle UICC_REFRESH_IND ISI message
       
   427          * @param aIsiMessage ISI message
       
   428          * @return void
       
   429          */
       
   430         void UiccRefreshInd( const TIsiReceiveC &aIsiMessage );
       
   431 
       
   432         /**
       
   433          * Handle UICC_REFRESH_RESP ISI message
       
   434          * @param aIsiMessage ISI message
       
   435          * @return void
       
   436          */
       
   437         void UiccRefreshResp( const TIsiReceiveC &aIsiMessage );
       
   438 
       
   439         /**
       
   440          * Create UICC_REFRESH_REQ ISI message
       
   441          * @param aStatus Status
       
   442          * @return Symbian error code
       
   443          */
       
   444         TInt UiccRefreshReq( TUint8 aStatus );
       
   445 
       
   446        /** Complete rerfesh handling
       
   447         * @param aIsiMessage ISI message
       
   448         * @return void
       
   449         */
       
   450        void HandleUiccRefresh( const TIsiReceiveC &aIsiMessage );
       
   451 
       
   452 
   273     //ATTRIBUTES
   453     //ATTRIBUTES
   274     public:
   454     public:
   275         //none
   455         //none
   276 
   456 
   277     protected:
   457     protected:
   333         // Keeps track on nokiatsy internal refresh
   513         // Keeps track on nokiatsy internal refresh
   334         TUint8 iInternalRefreshFiles;
   514         TUint8 iInternalRefreshFiles;
   335 
   515 
   336         // Keeps track if any errors happened during re-reading of cached files
   516         // Keeps track if any errors happened during re-reading of cached files
   337         TBool iRefreshError;
   517         TBool iRefreshError;
       
   518 
       
   519         // Flag for refresh completing
       
   520         TBool iCompleteRefresfDone;
       
   521 
       
   522         // Stores temporarily ACL status going to be set
       
   523         RMobilePhone::TAPNControlListServiceStatus iAclStatus;
       
   524 
       
   525         TInt iOngoingAclIpc;
   338     };
   526     };
   339 
   527 
   340 #endif // CMMPHONEMESSHANDLER_H
   528 #endif // CMMPHONEMESSHANDLER_H
   341 
   529 
   342 //  End of file
   530 //  End of file