phoneengine/engineinfo/src/cpeengineinfoimpl.cpp
changeset 0 5f000ab63145
child 1 838b0a10d15b
equal deleted inserted replaced
-1:000000000000 0:5f000ab63145
       
     1 /*
       
     2 * Copyright (c) 2002-2008 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:  This module contains the implementation of CPEEngineInfoImpl class 
       
    15 *
       
    16 */
       
    17 
       
    18 // INCLUDE FILES
       
    19 #include "cpecallinfo.h"
       
    20 #include "cpeclientinformation.h"
       
    21 #include "cpeengineinfoimpl.h"
       
    22 #include <pepanic.pan>
       
    23 #include <telinternalpskeys.h>
       
    24 #include <cphcltdialdata.h>
       
    25 #include <PhCltTypes.h>
       
    26 #include <talogger.h>
       
    27 
       
    28 // ================= MEMBER FUNCTIONS ==========================================
       
    29 
       
    30 // -----------------------------------------------------------------------------
       
    31 // CPEEngineInfoImpl::CPEEngineInfoImpl
       
    32 // C++ default constructor can NOT contain any code, that
       
    33 // might leave.
       
    34 // -----------------------------------------------------------------------------
       
    35 //
       
    36 CPEEngineInfoImpl::CPEEngineInfoImpl()
       
    37     : iCurrentCalls( KPEMaximumNumberOfCalls )
       
    38     {
       
    39     iCallCommandInfo.iPhoneNumber = KNullDesC;
       
    40     iCallCommandInfo.iCallId = 0;
       
    41     iCallCommandInfo.iKeyCode = 0;
       
    42     iCallCommandInfo.iAudioVolume = KPENumberInitValue;
       
    43     iCallCommandInfo.iAudioMute = EFalse;
       
    44     iCallCommandInfo.iDtmfString = KNullDesC;
       
    45     iCallCommandInfo.iCallType = EPECallTypeUninitialized;
       
    46     iCallCommandInfo.iServiceId = 0;
       
    47     iBasicInfo.iAudioOutputPreference = EPSAudioPrivate;
       
    48     iBasicInfo.iALSLine = CCCECallParameters::ECCELineTypePrimary;
       
    49     iBasicInfo.iALSLineSupport = EFalse;
       
    50     iBasicInfo.iPhoneAudioRouteParameters.iAudioOutput = EPENotActive;
       
    51     iBasicInfo.iAudioVolume = KPEDefaultAudioVolume;
       
    52     iBasicInfo.iKeypadVolume = KPENumberInitValue;
       
    53     iBasicInfo.iAudioMute = EFalse;
       
    54     iBasicInfo.iDtmfString = KNullDesC;
       
    55     iBasicInfo.iErrorInfo.iErrorCode = ECCPErrorNone;
       
    56     iBasicInfo.iErrorInfo.iCallId = KPECallIdNotUsed;
       
    57     iBasicInfo.iProfileId = ECCPErrorNotFound;
       
    58     iBasicInfo.iProfileName = KNullDesC;
       
    59     iBasicInfo.iPhoneIdentityParameters.iManufacturer = KNullDesC;
       
    60     iBasicInfo.iPhoneIdentityParameters.iModel = KNullDesC;
       
    61     iBasicInfo.iPhoneIdentityParameters.iRevision = KNullDesC;
       
    62     iBasicInfo.iPhoneIdentityParameters.iSerialNumber = KNullDesC;
       
    63     iBasicInfo.iLastCallDuration = KPENumberInitValue;
       
    64     iBasicInfo.iVMBXNumbers.iVMBXL1 = KNullDesC;
       
    65     iBasicInfo.iVMBXNumbers.iVMBXL2 = KNullDesC;
       
    66     iBasicInfo.iRingingType = EProfileRingingTypeRinging;
       
    67     iBasicInfo.iTextToSpeech = EFalse;
       
    68     iBasicInfo.iPhoneNumberIsServiceCode = EFalse;
       
    69     iBasicInfo.iTwoDigitSupportStatus = EFalse;
       
    70     iBasicInfo.iLifeTimeData.iHours = 0;
       
    71     iBasicInfo.iLifeTimeData.iMinutes = 0;
       
    72 
       
    73     iBasicInfo.iNetworkRegistrationStatus = ENWStatusRegistrationUnknown;
       
    74 
       
    75     iCallCommandInfo.iIdRestrict = RMobileCall::EIdRestrictDefault;
       
    76     iCallCommandInfo.iEmergencyNumber = KNullDesC;
       
    77     
       
    78     iCallCommandInfo.iTransferToAddress = KNullDesC;
       
    79     iCallCommandInfo.iForwardToAddressIndex = ECCPErrorNotFound;
       
    80     iBasicInfo.iActiveForward.iActiveType = RMobilePhone::ECFUnconditionalActive;
       
    81     iBasicInfo.iActiveForward.iServiceGroup =  RMobilePhone::EServiceUnspecified;
       
    82     iBasicInfo.iBarringInfo.iGroupCount = KPENumberInitValue;
       
    83     for( TInt i = 0; i < KPEMaxServiceGroup; i++ )
       
    84         {
       
    85         __ASSERT_DEBUG( 
       
    86             iBasicInfo.iBarringInfo.iBarredInfo.Count() > i, 
       
    87             Panic( EPEPanicIndexOutOfRange ) );
       
    88         iBasicInfo.iBarringInfo.iBarredInfo[i].iCondition = RMobilePhone::EBarUnspecified;
       
    89         iBasicInfo.iBarringInfo.iBarredInfo[i].iServiceGroup = 
       
    90             RMobilePhone::EServiceUnspecified;
       
    91         iBasicInfo.iBarringInfo.iBarredInfo[i].iStatus = 
       
    92             RMobilePhone::ECallBarringStatusUnknown;
       
    93         }
       
    94     iBasicInfo.iSSCommandInfo.action = EPESSActionUnspecified;
       
    95     iBasicInfo.iSSCommandInfo.type = EPESSTypeUnspecified;
       
    96     iBasicInfo.iSSCommandInfo.group = RMobilePhone::EServiceUnspecified;
       
    97     iBasicInfo.iSimState = EPESimStatusUninitialized;
       
    98     iBasicInfo.iSecureSpecified = ETrue; 
       
    99     iBasicInfo.iDataPortName = KNullDesC;
       
   100     iBasicInfo.iSwitchToOngoing = EFalse;
       
   101     iConferenceCallInfo.iConferenceCallState = EPEStateConferenceIdle;
       
   102     }
       
   103 
       
   104 // -----------------------------------------------------------------------------
       
   105 // CPEEngineInfoImpl::NewL
       
   106 // Two-phased constructor.
       
   107 // -----------------------------------------------------------------------------
       
   108 //
       
   109 CPEEngineInfoImpl* CPEEngineInfoImpl::NewL()
       
   110     {
       
   111     CPEEngineInfoImpl* self = new ( ELeave ) CPEEngineInfoImpl;
       
   112     CleanupStack::PushL( self );
       
   113     self->ConstructL();
       
   114     CleanupStack::Pop( self );
       
   115     return self;
       
   116     }
       
   117 
       
   118 // -----------------------------------------------------------------------------
       
   119 // CPEEngineInfoImpl::ConstructL
       
   120 // Initializes class member variables
       
   121 // -----------------------------------------------------------------------------
       
   122 //
       
   123 void CPEEngineInfoImpl::ConstructL()
       
   124     {
       
   125     iCallParams = CCCECallParameters::NewL();
       
   126 
       
   127     iRemoteInfo = new ( ELeave ) RPointerArray<CPERemoteInfo>( KPEMaximumNumberOfCalls );
       
   128 
       
   129     for ( TInt i = 0; i < KPEMaximumNumberOfCalls; i++ )
       
   130         {
       
   131         TEFLOGSTRING( KTAOBJECT, "CPEEngineInfoImpl::ConstructL" );
       
   132         CPERemoteInfo* remoteInfo = CPERemoteInfo::NewL();
       
   133         CleanupStack::PushL( remoteInfo );
       
   134         // associate this remote info instance with a call id
       
   135         remoteInfo->SetCallId( i );
       
   136         iRemoteInfo->InsertL( remoteInfo, i );
       
   137         CleanupStack::Pop( remoteInfo );
       
   138         
       
   139         CPECallInfo* callInfo = CPECallInfo::NewL();
       
   140         CleanupStack::PushL( callInfo );
       
   141         iCurrentCalls.AppendL( callInfo );
       
   142         CleanupStack::Pop( callInfo );
       
   143         }
       
   144         
       
   145     for( TInt i = 0 ; i < KPEMaximumNumberOfCalls ; i++ ) 
       
   146         {
       
   147         ResetCallInfo( i );    // Resets every call.
       
   148         }
       
   149     }
       
   150 
       
   151 // Destructor
       
   152 CPEEngineInfoImpl::~CPEEngineInfoImpl()
       
   153     {
       
   154     if ( iRemoteInfo )
       
   155         {
       
   156         iRemoteInfo->ResetAndDestroy();
       
   157         iRemoteInfo->Close();
       
   158         delete iRemoteInfo;
       
   159         iRemoteInfo = NULL;
       
   160         }
       
   161     delete iCallParams;
       
   162     
       
   163     iCurrentCalls.ResetAndDestroy();
       
   164     iCurrentCalls.Close();
       
   165     }
       
   166 
       
   167 // -----------------------------------------------------------------------------
       
   168 // CPEEngineInfoImpl::AlertForGroup
       
   169 // Gets group ids  from the TPEBasicInfo structure.
       
   170 // -----------------------------------------------------------------------------
       
   171 //
       
   172 const TArray< TContactItemId > CPEEngineInfoImpl::AlertForGroup() const
       
   173     {
       
   174     return iAlertForGroup.Array();
       
   175     }
       
   176 
       
   177 // -----------------------------------------------------------------------------
       
   178 // CPEEngineInfoImpl::ALSLine
       
   179 // Gets active als line of the phone.
       
   180 // -----------------------------------------------------------------------------
       
   181 //
       
   182 const CCCECallParameters::TCCELineType& CPEEngineInfoImpl::ALSLine() const
       
   183     {
       
   184     return iBasicInfo.iALSLine;
       
   185     }    
       
   186 
       
   187 
       
   188 // -----------------------------------------------------------------------------
       
   189 // CPEEngineInfoImpl::ALSLine
       
   190 // Gets active als line of the phone.
       
   191 // -----------------------------------------------------------------------------
       
   192 //
       
   193 const TBool& CPEEngineInfoImpl::ALSLineSupport() const
       
   194     {
       
   195     TEFLOGSTRING2( KTAMESIN,"CPEEngineInfoImpl::ALSLineSupport(),iALSLineSupport: %d"
       
   196         , iBasicInfo.iALSLineSupport );
       
   197     return iBasicInfo.iALSLineSupport;
       
   198     }  
       
   199     
       
   200 // -----------------------------------------------------------------------------
       
   201 // CPEEngineInfoImpl::AudioMute
       
   202 // Gets audio mute value from the TPEBasicInfo structure.
       
   203 // -----------------------------------------------------------------------------
       
   204 //
       
   205 const TBool& CPEEngineInfoImpl::AudioMute() const
       
   206     {
       
   207     return iBasicInfo.iAudioMute;
       
   208     }
       
   209 
       
   210 // -----------------------------------------------------------------------------
       
   211 // CPEEngineInfoImpl::AudioOutput
       
   212 // Gets audio output value from the TPEBasicInfo structure.
       
   213 // -----------------------------------------------------------------------------
       
   214 //
       
   215 const TPEAudioOutput& CPEEngineInfoImpl::AudioOutput() const
       
   216     {
       
   217     TEFLOGSTRING2( KTAINT, 
       
   218         "PE CPEEngineInfoImpl::AudioOutput: iBasicInfo.iAudioOutput: %d", 
       
   219         iBasicInfo.iPhoneAudioRouteParameters.iAudioOutput );
       
   220     return iBasicInfo.iPhoneAudioRouteParameters.iAudioOutput;
       
   221     }
       
   222 
       
   223 // -----------------------------------------------------------------------------
       
   224 // CPEEngineInfoImpl::PhoneIdentityParameters
       
   225 // Gets the phone identity parameters from the TPEBasicInfo structure
       
   226 // (other items were commented in a header).
       
   227 // -----------------------------------------------------------------------------
       
   228 //
       
   229 const TPEPhoneAudioRouteParameters& CPEEngineInfoImpl::RouteParameters() const
       
   230     {
       
   231     return iBasicInfo.iPhoneAudioRouteParameters;
       
   232     }
       
   233  
       
   234 // -----------------------------------------------------------------------------
       
   235 // CPEEngineInfoImpl::AudioOutputAvailable
       
   236 // Gets audio output path availability status from array
       
   237 // -----------------------------------------------------------------------------
       
   238 //
       
   239 TBool CPEEngineInfoImpl::AudioOutputAvailable( 
       
   240         const TPEAudioOutput aOutput ) const 
       
   241     {
       
   242     __ASSERT_ALWAYS( ( EPENotActive <= aOutput && 
       
   243         aOutput <= EPETTY ), Panic( EPEPanicInvalidParameter ) );
       
   244         
       
   245     TBool available( EFalse );
       
   246     // find given output from the available outputs array
       
   247     for (TInt i = 0; i < iAvailableAudioOutputs.Count(); i++)
       
   248         {
       
   249         if ( iAvailableAudioOutputs[i] == aOutput )
       
   250             {
       
   251             available = ETrue;
       
   252             }
       
   253         }
       
   254     return available;
       
   255     }
       
   256 
       
   257 // -----------------------------------------------------------------------------
       
   258 // CPEEngineInfoImpl::AudioMuteCommand
       
   259 // Gets audio mute command value from the TPECallCommandInfo structure.
       
   260 // -----------------------------------------------------------------------------
       
   261 //
       
   262 const TBool& CPEEngineInfoImpl::AudioMuteCommand() const
       
   263     {
       
   264     return iCallCommandInfo.iAudioMute;
       
   265     }
       
   266 
       
   267 // -----------------------------------------------------------------------------
       
   268 // CPEEngineInfoImpl::AudioOutputCommand
       
   269 // Gets audio output command value from the TPECallCommandInfo structure.
       
   270 // -----------------------------------------------------------------------------
       
   271 //
       
   272 const TPEAudioOutput& CPEEngineInfoImpl::AudioOutputCommand() const
       
   273     {
       
   274     return iCallCommandInfo.iAudioOutput;
       
   275     }
       
   276 
       
   277 // -----------------------------------------------------------------------------
       
   278 // CPEEngineInfoImpl::ShowNoteCommand
       
   279 // Gets audio note command value from the TPECallCommandInfo structure.
       
   280 // -----------------------------------------------------------------------------
       
   281 //
       
   282 TBool CPEEngineInfoImpl::ShowNoteCommand() const
       
   283     {
       
   284     return iCallCommandInfo.iShowNote;
       
   285     }
       
   286         
       
   287 // -----------------------------------------------------------------------------
       
   288 // CPEEngineInfoImpl::AudioOutputPreference
       
   289 // Gets audio output preference value from the TPEBasicInfo structure.
       
   290 // -----------------------------------------------------------------------------
       
   291 //
       
   292 const TInt& CPEEngineInfoImpl::AudioOutputPreference() const
       
   293     {
       
   294     return iBasicInfo.iAudioOutputPreference;
       
   295     }
       
   296 
       
   297 // -----------------------------------------------------------------------------
       
   298 // CPEEngineInfoImpl::AudioVolume
       
   299 // Gets audio volume value from the TPEBasicInfo structure.
       
   300 // -----------------------------------------------------------------------------
       
   301 //
       
   302 const TInt& CPEEngineInfoImpl::AudioVolume() const
       
   303     {
       
   304     TEFLOGSTRING2( KTAINT, 
       
   305         "PE CPEEngineInfoImpl::AudioVolume, volume: %d", iBasicInfo.iAudioVolume );
       
   306     return iBasicInfo.iAudioVolume;
       
   307     }
       
   308 
       
   309 // -----------------------------------------------------------------------------
       
   310 // CPEEngineInfoImpl::AudioVolumeCommand
       
   311 // Gets audio volume command value from the TPECallCommandInfo structure.
       
   312 // -----------------------------------------------------------------------------
       
   313 //
       
   314 const TInt& CPEEngineInfoImpl::AudioVolumeCommand() const
       
   315     {
       
   316     TEFLOGSTRING2( KTAINT, 
       
   317         "PE CPEEngineInfoImpl::AudioVolumeCommand, volume: %d", 
       
   318         iCallCommandInfo.iAudioVolume );
       
   319     return iCallCommandInfo.iAudioVolume;
       
   320     } 
       
   321 
       
   322 // -----------------------------------------------------------------------------
       
   323 // CPEEngineInfoImpl::CallClientInformation
       
   324 // Gets phone client information from the TPECallInfo structure.
       
   325 // -----------------------------------------------------------------------------
       
   326 //
       
   327 const MPEClientInformation& CPEEngineInfoImpl::CallClientInformation(
       
   328         const TInt aCallId ) const
       
   329     {
       
   330     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   331     return iCurrentCalls[ aCallId ]->ClientInformation();
       
   332     }
       
   333 
       
   334 // -----------------------------------------------------------------------------
       
   335 // CPEEngineInfoImpl::CallDirection
       
   336 // Gets the call direction.
       
   337 // -----------------------------------------------------------------------------
       
   338 //
       
   339 RMobileCall::TMobileCallDirection CPEEngineInfoImpl::CallDirection( 
       
   340         const TInt aCallId ) const
       
   341     {
       
   342     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   343     return iCurrentCalls[ aCallId ]->CallDirection();
       
   344     }
       
   345 
       
   346 // -----------------------------------------------------------------------------
       
   347 // CPEEngineInfoImpl::CallDuration
       
   348 // Gets the duration of the last call to idle.
       
   349 // -----------------------------------------------------------------------------
       
   350 //
       
   351 const TInt& CPEEngineInfoImpl::CallDuration() const
       
   352     {
       
   353     return iBasicInfo.iLastCallDuration;
       
   354     }
       
   355 
       
   356 // -----------------------------------------------------------------------------
       
   357 // CPEEngineInfoImpl::CallDuration
       
   358 // Gets the duration of the call.
       
   359 // -----------------------------------------------------------------------------
       
   360 //
       
   361 TTimeIntervalSeconds CPEEngineInfoImpl::CallDuration(
       
   362         const TInt aCallId ) const
       
   363     {
       
   364     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   365     return iCurrentCalls[ aCallId ]->Duration();
       
   366     }
       
   367 
       
   368 // -----------------------------------------------------------------------------
       
   369 // CPEEngineInfoImpl::CallId
       
   370 // Gets the identification number of the call from the TPECallCommandInfo structure. 
       
   371 // -----------------------------------------------------------------------------
       
   372 //
       
   373 const TInt& CPEEngineInfoImpl::CallId() const
       
   374     {
       
   375     return iCallCommandInfo.iCallId;
       
   376     }
       
   377     
       
   378 // -----------------------------------------------------------------------------
       
   379 // CPEEngineInfoImpl::CallALSLine
       
   380 // Gets als line value from the TPECallInfo structure.
       
   381 // -----------------------------------------------------------------------------
       
   382 //
       
   383 CCCECallParameters::TCCELineType CPEEngineInfoImpl::CallALSLine( 
       
   384         const TInt aCallId ) const
       
   385     {
       
   386     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   387     return iCurrentCalls[ aCallId ]->AlsLine();
       
   388     }
       
   389 
       
   390 // -----------------------------------------------------------------------------
       
   391 // CPEEngineInfoImpl::CallStartTime
       
   392 // Gets the start time of the call.
       
   393 // -----------------------------------------------------------------------------
       
   394 //
       
   395 const TTime& CPEEngineInfoImpl::CallStartTime(
       
   396         const TInt aCallId ) const
       
   397     {
       
   398     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   399     return iCurrentCalls[ aCallId ]->StartTime();
       
   400     }
       
   401 
       
   402 // -----------------------------------------------------------------------------
       
   403 // CPEEngineInfoImpl::CallState
       
   404 // Gets the state of the call.
       
   405 // -----------------------------------------------------------------------------
       
   406 //
       
   407 TPEState CPEEngineInfoImpl::CallState( 
       
   408         const TInt aCallId ) const
       
   409     {
       
   410     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   411     return iCurrentCalls[ aCallId ]->CallState();
       
   412     }
       
   413 
       
   414 // -----------------------------------------------------------------------------
       
   415 // CPEEngineInfoImpl::CallType
       
   416 // Gets the type of the call.
       
   417 // -----------------------------------------------------------------------------
       
   418 //
       
   419 TPECallType CPEEngineInfoImpl::CallType(
       
   420         const TInt aCallId ) const
       
   421     {
       
   422     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   423     return iCurrentCalls[ aCallId ]->CallType();
       
   424     }
       
   425 
       
   426 // -----------------------------------------------------------------------------
       
   427 // CPEEngineInfoImpl::CallTypeCommand
       
   428 // Gets call type information for the attempted call
       
   429 // -----------------------------------------------------------------------------
       
   430 //
       
   431 const TPECallType& CPEEngineInfoImpl::CallTypeCommand() const
       
   432     {
       
   433     return iCallCommandInfo.iCallType;
       
   434     }
       
   435 
       
   436 // -----------------------------------------------------------------------------
       
   437 // CPEEngineInfoImpl::ConferenceCallState
       
   438 // -----------------------------------------------------------------------------
       
   439 //
       
   440 TPEState CPEEngineInfoImpl::ConferenceCallState() const
       
   441     {
       
   442     return iConferenceCallInfo.iConferenceCallState;
       
   443     }
       
   444 
       
   445 // -----------------------------------------------------------------------------
       
   446 // CPEEngineInfoImpl::IsSecureCall
       
   447 // Gets secured status from call info
       
   448 // -----------------------------------------------------------------------------
       
   449 //
       
   450 TBool CPEEngineInfoImpl::IsSecureCall( const TInt aCallId ) const
       
   451     {
       
   452     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   453     TInt isSecured = EFalse; 
       
   454     
       
   455     // Conference call secure status
       
   456     if ( KPEConferenceCallID == aCallId )
       
   457         {
       
   458         TInt count = iCurrentCalls.Count();
       
   459 
       
   460         for ( TInt i = 0; i < count; i++ )
       
   461             {
       
   462             if ( iCurrentCalls[ i ]->ConferenceMemberId() != KPECallIdNotUsed )
       
   463             {
       
   464                 if ( iCurrentCalls[ i ]->SecureStatus() )
       
   465                     {
       
   466                     isSecured = ETrue;
       
   467                     }
       
   468                 else
       
   469                     {
       
   470                     isSecured = EFalse;
       
   471                     break;
       
   472                     }
       
   473                 }
       
   474             }
       
   475         }
       
   476     else
       
   477         {
       
   478         isSecured = iCurrentCalls[ aCallId ]->SecureStatus();
       
   479         }
       
   480     
       
   481     return isSecured;
       
   482     }
       
   483 
       
   484 // -----------------------------------------------------------------------------
       
   485 // CPEEngineInfoImpl::DataPortName
       
   486 // Gets the name of data port currently on-loan.
       
   487 // -----------------------------------------------------------------------------
       
   488 //
       
   489 const TName& CPEEngineInfoImpl::DataPortName() const
       
   490     {
       
   491     return iBasicInfo.iDataPortName;
       
   492     }
       
   493         
       
   494 // -----------------------------------------------------------------------------
       
   495 // CPEEngineInfoImpl::DtmfPostFix
       
   496 // Gets dtmf postfix value from the TPEBasicInfo structure.
       
   497 // -----------------------------------------------------------------------------
       
   498 //
       
   499 const TPEDtmfString& CPEEngineInfoImpl::DtmfPostFix( const TInt aCallId ) const
       
   500     {
       
   501     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   502     return iCurrentCalls[ aCallId ]->DtmfPostFix();
       
   503     }
       
   504 
       
   505 // -----------------------------------------------------------------------------
       
   506 // CPEEngineInfoImpl::DtmfString
       
   507 // Gets dtmf string value from the TPEBasicInfo structure.
       
   508 // -----------------------------------------------------------------------------
       
   509 //
       
   510 const TPEDtmfString& CPEEngineInfoImpl::DtmfString() const
       
   511     {
       
   512     return iBasicInfo.iDtmfString;
       
   513     }
       
   514 
       
   515 // -----------------------------------------------------------------------------
       
   516 // CPEEngineInfoImpl::DtmfStringCommand
       
   517 // Gets dtmf string command value from TPECallCommandInfo-structure
       
   518 // -----------------------------------------------------------------------------
       
   519 //
       
   520 const TPEDtmfString& CPEEngineInfoImpl::DtmfStringCommand() const
       
   521     {
       
   522     return iCallCommandInfo.iDtmfString; 
       
   523     }
       
   524 
       
   525 // -----------------------------------------------------------------------------
       
   526 // CPEEngineInfoImpl::ErrorInfo
       
   527 // Gets the error code value of the phone from the TPEBasicInfo structure.
       
   528 // -----------------------------------------------------------------------------
       
   529 //
       
   530 const TPEErrorInfo& CPEEngineInfoImpl::ErrorInfo() const
       
   531     {
       
   532     return iBasicInfo.iErrorInfo;
       
   533     }
       
   534 
       
   535 // -----------------------------------------------------------------------------
       
   536 // CPEEngineInfoImpl::InbandTone
       
   537 // Gets correct inband tone for specific call state transition or error
       
   538 // -----------------------------------------------------------------------------
       
   539 //
       
   540 const TCCPTone& CPEEngineInfoImpl::InbandTone() const 
       
   541     {
       
   542     return iBasicInfo.iInbandTone; 
       
   543     }
       
   544 
       
   545 // -----------------------------------------------------------------------------
       
   546 // CPEEngineInfoImpl::KeyCode
       
   547 //  Gets key code value.
       
   548 // -----------------------------------------------------------------------------
       
   549 //
       
   550 const TChar& CPEEngineInfoImpl::KeyCode() const
       
   551     {
       
   552     return iCallCommandInfo.iKeyCode;
       
   553     }
       
   554 
       
   555 // -----------------------------------------------------------------------------
       
   556 // CPEEngineInfoImpl::KeypadVolume
       
   557 // Gets Keypad volume value from the TPEBasicInfo structure.
       
   558 // (other items were commented in a header).
       
   559 // -----------------------------------------------------------------------------
       
   560 //
       
   561 const TInt& CPEEngineInfoImpl::KeypadVolume() const
       
   562     {
       
   563     return iBasicInfo.iKeypadVolume;
       
   564     }
       
   565 
       
   566 // -----------------------------------------------------------------------------
       
   567 // CPEEngineInfoImpl::LifeTimerData
       
   568 // Gets lifetimerdata from the TPEBasicInfo structure.
       
   569 // (other items were commented in a header).
       
   570 // -----------------------------------------------------------------------------
       
   571 //
       
   572 const TPELifeTimeData& CPEEngineInfoImpl::LifeTimerData() const
       
   573     {
       
   574     return iBasicInfo.iLifeTimeData;
       
   575     }
       
   576 
       
   577 // -----------------------------------------------------------------------------
       
   578 // CPEEngineInfoImpl::LoggingIndicator
       
   579 // Get logging indicator from TPECallInfo.
       
   580 // (other items were commented in a header).
       
   581 // -----------------------------------------------------------------------------
       
   582 //
       
   583 TBool CPEEngineInfoImpl::LoggingIndicator(
       
   584         const TInt aCallId ) const
       
   585     {
       
   586     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   587     __ASSERT_ALWAYS( !CallIdCheck::IsConference( aCallId ), Panic( EPEPanicIllegalCommand ) );
       
   588     return iCurrentCalls[ aCallId ]->LoggingEnabled();
       
   589     }
       
   590 
       
   591 // -----------------------------------------------------------------------------
       
   592 // CPEEngineInfoImpl::MissedCall
       
   593 // Get missed call indicator from TPECallInfo.
       
   594 // (other items were commented in a header).
       
   595 // -----------------------------------------------------------------------------
       
   596 //
       
   597 TBool CPEEngineInfoImpl::MissedCall(
       
   598         const TInt aCallId ) const
       
   599     {
       
   600     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   601     __ASSERT_ALWAYS( !CallIdCheck::IsConference( aCallId ), Panic( EPEPanicIllegalCommand ) );
       
   602     return iCurrentCalls[ aCallId ]->MissedCall();     
       
   603     }
       
   604 
       
   605 // -----------------------------------------------------------------------------
       
   606 // CPEEngineInfoImpl::NetworkInformation
       
   607 // Return network information
       
   608 // (other items were commented in a header).
       
   609 // -----------------------------------------------------------------------------
       
   610 //
       
   611 const TNWNetworkRegistrationStatus& CPEEngineInfoImpl::NetworkRegistrationStatus() const
       
   612     {
       
   613     return iBasicInfo.iNetworkRegistrationStatus;
       
   614     }
       
   615 
       
   616 // -----------------------------------------------------------------------------
       
   617 // CPEEngineInfoImpl::PersonalToneStatus
       
   618 // Gets personal tone status from the TPEBasicInfo structure.
       
   619 // (other items were commented in a header).
       
   620 // -----------------------------------------------------------------------------
       
   621 //
       
   622 const TBool& CPEEngineInfoImpl::PersonalToneStatus() const
       
   623     {
       
   624     return iBasicInfo.iPersonalToneStatus;
       
   625     }
       
   626 
       
   627 // -----------------------------------------------------------------------------
       
   628 // CPEEngineInfoImpl::PhoneIdentityParameters
       
   629 // Gets the phone identity parameters from the TPEBasicInfo structure
       
   630 // -----------------------------------------------------------------------------
       
   631 //
       
   632 const TPEPhoneIdentityParameters& CPEEngineInfoImpl::PhoneIdentityParameters() const
       
   633     {
       
   634     return iBasicInfo.iPhoneIdentityParameters;
       
   635     }
       
   636 
       
   637 // -----------------------------------------------------------------------------
       
   638 // CPEEngineInfoImpl::PhoneNumber
       
   639 // Return the phone number from the TPECallCommandInfo structure.
       
   640 // -----------------------------------------------------------------------------
       
   641 //
       
   642 const TPEPhoneNumber& CPEEngineInfoImpl::PhoneNumber() const
       
   643     {
       
   644     return iCallCommandInfo.iPhoneNumber;
       
   645     }
       
   646 
       
   647 // -----------------------------------------------------------------------------
       
   648 // CPEEngineInfoImpl::PhoneNumberIsServiceCode
       
   649 // Return the phone number parsing result
       
   650 // -----------------------------------------------------------------------------
       
   651 //
       
   652 const TBool& CPEEngineInfoImpl::PhoneNumberIsServiceCode() const
       
   653     {
       
   654     return iBasicInfo.iPhoneNumberIsServiceCode;
       
   655     }
       
   656 
       
   657 // -----------------------------------------------------------------------------
       
   658 // CPEEngineInfoImpl::CallOriginCommand
       
   659 // Gets call origin for next call attempt
       
   660 // -----------------------------------------------------------------------------
       
   661 //
       
   662 const TPECallOrigin& CPEEngineInfoImpl::CallOriginCommand() const
       
   663 	{
       
   664 	return iCallCommandInfo.iCallOrigin;
       
   665 	}
       
   666         	
       
   667 // CPEEngineInfoImpl::ProfileId
       
   668 // Gets the profile id from the TPEBasicInfo structure.
       
   669 // -----------------------------------------------------------------------------
       
   670 //
       
   671 const TInt& CPEEngineInfoImpl::ProfileId() const
       
   672     {
       
   673     return iBasicInfo.iProfileId;
       
   674     }
       
   675 
       
   676 // -----------------------------------------------------------------------------
       
   677 // CPEEngineInfoImpl::ProfileName
       
   678 // Gets the profile name from the TPEBasicInfo structure.
       
   679 // -----------------------------------------------------------------------------
       
   680 //
       
   681 const TPEProfileName& CPEEngineInfoImpl::ProfileName() const
       
   682     {
       
   683     return iBasicInfo.iProfileName;
       
   684     }
       
   685 
       
   686 // -----------------------------------------------------------------------------
       
   687 // CPEEngineInfoImpl::RemoteIdentity
       
   688 // Gets the remote identity from the TPEBasicInfo structure.
       
   689 // -----------------------------------------------------------------------------
       
   690 //
       
   691 RMobileCall::TMobileCallRemoteIdentityStatus CPEEngineInfoImpl::RemoteIdentity(
       
   692         const TInt aCallId ) const
       
   693     {
       
   694     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   695     return iCurrentCalls[ aCallId ]->RemoteIdentity();
       
   696     }
       
   697 
       
   698 // -----------------------------------------------------------------------------
       
   699 // CPEEngineInfoImpl::RingingTone
       
   700 // Gets the ringing tone file name from the TPEBasicInfo structure.
       
   701 // -----------------------------------------------------------------------------
       
   702 // 
       
   703 const TPEContactFileName& CPEEngineInfoImpl::RingingTone(
       
   704         const TInt& aCallId ) const
       
   705     {
       
   706     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   707 
       
   708     if ( iCurrentCalls[aCallId]->AlsLine() == CCCECallParameters::ECCELineTypeAux )
       
   709         {
       
   710         return iBasicInfo.iRingingToneName2;
       
   711         }
       
   712     else if ( EPECallTypeVideo == iCurrentCalls[aCallId]->CallType() )
       
   713         {
       
   714         return iBasicInfo.iVideoCallRingingTone;
       
   715         }
       
   716     else
       
   717         {
       
   718         return iBasicInfo.iRingingToneName1;
       
   719         }
       
   720     }
       
   721     
       
   722 // -----------------------------------------------------------------------------
       
   723 // CPEEngineInfoImpl::RingingType 
       
   724 // Gets the ringingtype.
       
   725 // (other items were commented in a header).
       
   726 // -----------------------------------------------------------------------------
       
   727 //
       
   728 const TProfileRingingType& CPEEngineInfoImpl::RingingType() const
       
   729     {
       
   730     return iBasicInfo.iRingingType;
       
   731     }
       
   732     
       
   733 // -----------------------------------------------------------------------------
       
   734 // CPEEngineInfoImpl::RingingVolume
       
   735 // Gets the ringing volume.
       
   736 // (other items were commented in a header).
       
   737 // -----------------------------------------------------------------------------
       
   738 //
       
   739 const TInt& CPEEngineInfoImpl::RingingVolume() const
       
   740     {
       
   741     return iBasicInfo.iRingingVolume;
       
   742     }
       
   743 
       
   744 // -----------------------------------------------------------------------------
       
   745 // CPEEngineInfoImpl::TextToSpeech
       
   746 // Return the status of the text-to-speech preference setting.
       
   747 // (other items were commented in a header).
       
   748 // -----------------------------------------------------------------------------
       
   749 //
       
   750 const TBool& CPEEngineInfoImpl::TextToSpeech() const
       
   751     {
       
   752     return iBasicInfo.iTextToSpeech;
       
   753     }
       
   754 
       
   755 // -----------------------------------------------------------------------------
       
   756 // CPEEngineInfoImpl::UserToUserInformation
       
   757 // Return User to user information
       
   758 // (other items were commented in a header).
       
   759 // -----------------------------------------------------------------------------
       
   760 //    
       
   761 const TPEUserToUserInfo& CPEEngineInfoImpl::UserToUserInformation() const
       
   762     {
       
   763     return iCallCommandInfo.iUserToUserInfo;
       
   764     }
       
   765 
       
   766 // -----------------------------------------------------------------------------
       
   767 // CPEEngineInfoImpl::SetALSLine
       
   768 // Sets active als line value to the TPEBasicInfo structure
       
   769 // (other items were commented in a header).
       
   770 // -----------------------------------------------------------------------------
       
   771 //
       
   772 void CPEEngineInfoImpl::SetALSLine( 
       
   773     const CCCECallParameters::TCCELineType& aALSLine ) 
       
   774     {
       
   775     TEFLOGSTRING2( KTAINT, 
       
   776         "PE CPEEngineInfoImpl::SetALSLine: aALSLine: %d", aALSLine );
       
   777     __ASSERT_ALWAYS( ( CCCECallParameters::ECCELineTypePrimary <= aALSLine && aALSLine <= CCCECallParameters::ECCELineTypeAux ), 
       
   778         Panic( EPEPanicInvalidParameter ) );
       
   779     iBasicInfo.iALSLine = aALSLine;
       
   780     }
       
   781 
       
   782 
       
   783 // -----------------------------------------------------------------------------
       
   784 // CPEEngineInfoImpl::SetALSLine
       
   785 // Sets active als line value to the TPEBasicInfo structure
       
   786 // (other items were commented in a header).
       
   787 // -----------------------------------------------------------------------------
       
   788 //
       
   789 void CPEEngineInfoImpl::SetALSLineSupport( 
       
   790     const TBool& aALSLineSupport ) 
       
   791     {
       
   792     TEFLOGSTRING2( KTAINT, 
       
   793         "PE CPEEngineInfoImpl::ALSLineSupport: aALSLineSupport: %d", aALSLineSupport );
       
   794     iBasicInfo.iALSLineSupport = aALSLineSupport;
       
   795     }
       
   796     
       
   797 // -----------------------------------------------------------------------------
       
   798 // CPEEngineInfoImpl::SetAudioMuteCommand
       
   799 // Sets audio mode of the phone to the TPEBasicInfo structure.
       
   800 // (other items were commented in a header).
       
   801 // -----------------------------------------------------------------------------
       
   802 //
       
   803 void CPEEngineInfoImpl::SetAudioMuteCommand( 
       
   804         const TBool& aAudioMute )
       
   805     {
       
   806     TEFLOGSTRING2( KTAINT, 
       
   807         "PE CPEEngineInfoImpl::SetAudioMuteCommand, mute: %d", aAudioMute );
       
   808     iCallCommandInfo.iAudioMute = aAudioMute;
       
   809     }
       
   810 
       
   811 // -----------------------------------------------------------------------------
       
   812 // CPEEngineInfoImpl::SetAudioOutputCommand
       
   813 // Sets audio output path to the TPECallCommandInfo structure.
       
   814 // (other items were commented in a header).
       
   815 // -----------------------------------------------------------------------------
       
   816 //
       
   817 void CPEEngineInfoImpl::SetAudioOutputCommand( 
       
   818         const TPEAudioOutput& aOutput,
       
   819         const TBool aShowNote
       
   820          )
       
   821     {
       
   822     TEFLOGSTRING2( KTAINT, 
       
   823         "PE CPEEngineInfoImpl::SetAudioOutputCommand, output: %d", aOutput );
       
   824     __ASSERT_ALWAYS( ( EPENotActive <= aOutput && 
       
   825         aOutput <= EPETTY ), Panic( EPEPanicInvalidParameter ) );
       
   826     iCallCommandInfo.iAudioOutput = aOutput;
       
   827     iCallCommandInfo.iShowNote = aShowNote;
       
   828     }
       
   829 
       
   830 // -----------------------------------------------------------------------------
       
   831 // CPEEngineInfoImpl::SetAudioVolumeCommand
       
   832 // Sets audio mode of the phone to the TPEBasicInfo structure.
       
   833 // (other items were commented in a header).
       
   834 // -----------------------------------------------------------------------------
       
   835 //
       
   836 void CPEEngineInfoImpl::SetAudioVolumeCommand( 
       
   837         const TInt& aAudioVolume )
       
   838     {
       
   839     TEFLOGSTRING2( KTAINT, 
       
   840         "PE CPEEngineInfoImpl::SetAudioVolumeCommand, volume: %d", aAudioVolume );
       
   841     // No need to check that, is parameter value correct. Maximun value is 
       
   842     // platform depended. If the volume is not within this range, the volume 
       
   843     // is automatically set to minimum or maximum value based on the value 
       
   844     // that is being passed (by CMMFDevSound ).
       
   845     iCallCommandInfo.iAudioVolume = aAudioVolume;
       
   846     }
       
   847 
       
   848 // -----------------------------------------------------------------------------
       
   849 // CPEEngineInfoImpl::SetCallClientInformation
       
   850 // Sets phone client information to the TPECallInfo structure.
       
   851 // (other items were commented in a header).
       
   852 // -----------------------------------------------------------------------------
       
   853 //
       
   854 void CPEEngineInfoImpl::SetCallClientInformation( 
       
   855         const MPEClientInformation& aClientInformation, 
       
   856         const TInt aCallId )
       
   857     {
       
   858     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   859     iCurrentCalls[ aCallId ]->ClientInformation().Set( aClientInformation );
       
   860     }
       
   861 
       
   862 // -----------------------------------------------------------------------------
       
   863 // CPEEngineInfoImpl::SetCallDirection
       
   864 // Sets the call direction to the TPECallInfo structure.
       
   865 // (other items were commented in a header).
       
   866 // -----------------------------------------------------------------------------
       
   867 //
       
   868 void CPEEngineInfoImpl::SetCallDirection( 
       
   869         const RMobileCall::TMobileCallDirection& aCallDirection, 
       
   870         const TInt aCallId )
       
   871     {
       
   872     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   873     __ASSERT_ALWAYS( ( RMobileCall::EDirectionUnknown <= aCallDirection && 
       
   874         aCallDirection <= RMobileCall::EMobileTerminated ), Panic( EPEPanicInvalidParameter ) );
       
   875     iCurrentCalls[ aCallId ]->SetCallDirection( aCallDirection );
       
   876     }
       
   877 
       
   878 // -----------------------------------------------------------------------------
       
   879 // CPEEngineInfoImpl::SetCallDuration
       
   880 // Sets the duration of the call to the TPECallInfo structure.
       
   881 // (other items were commented in a header).
       
   882 // -----------------------------------------------------------------------------
       
   883 //
       
   884 void CPEEngineInfoImpl::SetCallDuration( 
       
   885         const TTimeIntervalSeconds& aCallDuration,  
       
   886         const TInt aCallId )
       
   887     {
       
   888     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   889     iCurrentCalls[ aCallId ]->SetDuration( aCallDuration );
       
   890     }
       
   891 
       
   892 // -----------------------------------------------------------------------------
       
   893 // CPEEngineInfoImpl::SetCallId
       
   894 // Sets the identification number of the call to the TPECallCommandInfo structure
       
   895 // (other items were commented in a header).
       
   896 // -----------------------------------------------------------------------------
       
   897 //
       
   898 void CPEEngineInfoImpl::SetCallId( 
       
   899         const TInt& aCallId )
       
   900     {
       
   901     __ASSERT_ALWAYS( CallIdCheck::IsValid( aCallId ), 
       
   902         Panic( EPEPanicCallIndexOutOfRange ) );
       
   903     iCallCommandInfo.iCallId = aCallId;
       
   904     }
       
   905 
       
   906 // -----------------------------------------------------------------------------
       
   907 // CPEEngineInfoImpl::SetCallStartTime
       
   908 // Sets the start time of the call to the TPECallInfo structure.
       
   909 // (other items were commented in a header).
       
   910 // -----------------------------------------------------------------------------
       
   911 //
       
   912 void CPEEngineInfoImpl::SetCallStartTime( 
       
   913         const TTime& aCallStartTime,
       
   914         const TInt aCallId )
       
   915     {
       
   916     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   917     iCurrentCalls[ aCallId ]->SetStartTime( aCallStartTime );
       
   918     }
       
   919 
       
   920 // -----------------------------------------------------------------------------
       
   921 // CPEEngineInfoImpl::SetCallState
       
   922 // Sets the state of the call to the TPECallInfo structure.
       
   923 // (other items were commented in a header).
       
   924 // -----------------------------------------------------------------------------
       
   925 //
       
   926 void CPEEngineInfoImpl::SetCallState( 
       
   927         const TPEState& aCallState, 
       
   928         const TInt aCallId )
       
   929     {
       
   930     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   931     __ASSERT_ALWAYS( !( aCallState > EPEStateMaximumState ), 
       
   932         Panic( EPEPanicInvalidParameter ) );
       
   933     iCurrentCalls[ aCallId ]->SetCallState( aCallState );
       
   934     }
       
   935 
       
   936 // -----------------------------------------------------------------------------
       
   937 // CPEEngineInfoImpl::SetCallType
       
   938 // Sets the type of the call.
       
   939 // -----------------------------------------------------------------------------
       
   940 //
       
   941 void CPEEngineInfoImpl::SetCallType( 
       
   942         const TPECallType& aCallType,   
       
   943         const TInt aCallId )
       
   944     {
       
   945     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
   946     __ASSERT_ALWAYS( ( EPECallTypeUninitialized <= aCallType &&
       
   947         aCallType <= EPECallTypeVoIP ), Panic( EPEPanicInvalidParameter ) );
       
   948     iCurrentCalls[ aCallId ]->SetCallType( aCallType );
       
   949     TEFLOGSTRING3( KTAINT, 
       
   950         "PE CPEEngineInfoImpl::SetCallType: call id: %d , aCallType: %d"
       
   951         ,aCallId ,aCallType );
       
   952     }
       
   953 
       
   954 // -----------------------------------------------------------------------------
       
   955 // CPEEngineInfoImpl::SetCallTypeCommand
       
   956 // Sets call type information for following command message
       
   957 // -----------------------------------------------------------------------------
       
   958 //
       
   959 void CPEEngineInfoImpl::SetCallTypeCommand( 
       
   960         const TPECallType& aCallType )
       
   961     {
       
   962     __ASSERT_ALWAYS( ( EPECallTypeUninitialized <= aCallType &&
       
   963         aCallType <= EPECallTypeVoIP ), Panic( EPEPanicInvalidParameter ) );
       
   964     iCallCommandInfo.iCallType = aCallType;
       
   965     }
       
   966 
       
   967 // -----------------------------------------------------------------------------
       
   968 // CPEEngineInfoImpl::SetConferenceCallState
       
   969 // -----------------------------------------------------------------------------
       
   970 //
       
   971 void CPEEngineInfoImpl::SetConferenceCallState(
       
   972         const TPEState& aCallState )
       
   973     {
       
   974     __ASSERT_ALWAYS( !( aCallState > EPEStateMaximumState ), 
       
   975         Panic( EPEPanicInvalidParameter ) );
       
   976     iConferenceCallInfo.iConferenceCallState = aCallState;
       
   977     }
       
   978 
       
   979 
       
   980 
       
   981 // -----------------------------------------------------------------------------
       
   982 // CPEEngineInfoImpl::SetDataPortName
       
   983 // Sets the name of data port currently on-loan.
       
   984 // -----------------------------------------------------------------------------
       
   985 //
       
   986 void CPEEngineInfoImpl::SetDataPortName(
       
   987         const TName& aDataPortName )
       
   988     {
       
   989     TEFLOGSTRING2( KTAINT, 
       
   990         "PE CPEEngineInfoImpl::SetDataPortName: dataport name = %S", &aDataPortName );
       
   991     iBasicInfo.iDataPortName = aDataPortName;
       
   992     }
       
   993     
       
   994 // -----------------------------------------------------------------------------
       
   995 // CPEEngineInfoImpl::SetDtmfStringCommand
       
   996 // Sets the dtmf string value to the TPECommandInfo structure.
       
   997 // (other items were commented in a header).
       
   998 // -----------------------------------------------------------------------------
       
   999 //
       
  1000 void CPEEngineInfoImpl::SetDtmfStringCommand( 
       
  1001         const TPEDtmfString& aDtmfString )
       
  1002     {
       
  1003     __ASSERT_DEBUG( !( aDtmfString.Length() > KPEDtmfMaxLength ),
       
  1004         Panic( EPEPanicInvalidParameter ) );
       
  1005     iCallCommandInfo.iDtmfString = aDtmfString;
       
  1006     }
       
  1007 
       
  1008 // -----------------------------------------------------------------------------
       
  1009 // CPEEngineInfoImpl::SetKeyCode
       
  1010 // Sets the key code value to the TPECallCommandInfo structure.
       
  1011 // -----------------------------------------------------------------------------
       
  1012 //
       
  1013 void CPEEngineInfoImpl::SetKeyCode( 
       
  1014         const TChar& aKeyCode )
       
  1015     {
       
  1016     iCallCommandInfo.iKeyCode = aKeyCode;
       
  1017     }
       
  1018     
       
  1019 // -----------------------------------------------------------------------------
       
  1020 // CPEEngineInfoImpl::SetLoggingIndicator
       
  1021 // Set logging indicator to TPECallInfo.
       
  1022 // -----------------------------------------------------------------------------
       
  1023 //
       
  1024 void CPEEngineInfoImpl::SetLoggingIndicator(
       
  1025         const TBool aLoggingIndicator, 
       
  1026         const TInt aCallId )
       
  1027     {
       
  1028     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1029     __ASSERT_ALWAYS( !CallIdCheck::IsConference( aCallId ), Panic( EPEPanicCallIndexOutOfRange ) );
       
  1030     iCurrentCalls[ aCallId ]->SetLoggingEnabled( aLoggingIndicator );
       
  1031     TEFLOGSTRING3( KTAINT, 
       
  1032         "PE CPEEngineInfoImpl::SetLoggingIndicator: call id: %d , iLoggingEnabled: %d"
       
  1033         ,aCallId ,aLoggingIndicator );
       
  1034     }
       
  1035 
       
  1036 // -----------------------------------------------------------------------------
       
  1037 // CPEEngineInfoImpl::SetMissedCall
       
  1038 // Set missed call indicator to TPECallInfo.
       
  1039 // -----------------------------------------------------------------------------
       
  1040 //
       
  1041 void CPEEngineInfoImpl::SetMissedCall(
       
  1042         const TBool& aMissedCall,    
       
  1043         const TInt aCallId )
       
  1044     {
       
  1045     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1046     __ASSERT_ALWAYS( !CallIdCheck::IsConference( aCallId ), Panic( EPEPanicCallIndexOutOfRange ) );
       
  1047     iCurrentCalls[ aCallId ]->SetMissedCall( aMissedCall );
       
  1048     }
       
  1049     
       
  1050 // -----------------------------------------------------------------------------
       
  1051 // CPEEngineInfoImpl::SetPhoneNumber
       
  1052 // Sets the phone number to the TPECallCommandInfo structure.
       
  1053 // -----------------------------------------------------------------------------
       
  1054 //
       
  1055 void CPEEngineInfoImpl::SetPhoneNumber( 
       
  1056         const TPEPhoneNumber& aPhoneNumber )
       
  1057     {
       
  1058     __ASSERT_DEBUG( !( aPhoneNumber.Length() > KPEPhoneNumberMaxLength ),
       
  1059         Panic( EPEPanicExternalDataIdOutOfRange ) );
       
  1060     iCallCommandInfo.iPhoneNumber = aPhoneNumber;
       
  1061     }
       
  1062 
       
  1063 // -----------------------------------------------------------------------------
       
  1064 // CPEEngineInfoImpl::SetRemoteIdentity
       
  1065 // Sets the remote party status to the TPECallInfo structure.
       
  1066 // -----------------------------------------------------------------------------
       
  1067 //
       
  1068 void CPEEngineInfoImpl::SetRemoteIdentity( 
       
  1069     const RMobileCall::TMobileCallRemoteIdentityStatus& aIdentity, 
       
  1070     const TInt aCallId )
       
  1071     {
       
  1072     TEFLOGSTRING2( KTAINT, 
       
  1073         "PE CPEEngineInfoImpl::SetRemoteIdentity: aIdentity = %d", aIdentity );
       
  1074     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1075     __ASSERT_ALWAYS( ( RMobileCall::ERemoteIdentityUnknown <= aIdentity &&
       
  1076         aIdentity <= RMobileCall::ERemoteIdentityAvailableNoCliUnavailable ), 
       
  1077         Panic( EPEPanicInvalidParameter ) );    
       
  1078     iCurrentCalls[ aCallId ]->SetRemoteIdentity( aIdentity );
       
  1079     }
       
  1080 
       
  1081 // -----------------------------------------------------------------------------
       
  1082 // CPEEngineInfoImpl::TwoDigitSupportStatus
       
  1083 // Return the status of the two dial digit.
       
  1084 // (other items were commented in a header).
       
  1085 // -----------------------------------------------------------------------------
       
  1086 //
       
  1087 
       
  1088 const TBool& CPEEngineInfoImpl::TwoDigitSupportStatus() const
       
  1089     {
       
  1090     return iBasicInfo.iTwoDigitSupportStatus;
       
  1091     }
       
  1092 
       
  1093 // -----------------------------------------------------------------------------
       
  1094 // CPEEngineInfoImpl::VoiceMailBoxNumberLine1
       
  1095 // Gets the VoiceMailBoxNumber for line 1.
       
  1096 // (other items were commented in a header).
       
  1097 // -----------------------------------------------------------------------------
       
  1098 //
       
  1099 const TPEPhoneNumber& CPEEngineInfoImpl::VoiceMailBoxNumberLine1() const
       
  1100     {
       
  1101     return iBasicInfo.iVMBXNumbers.iVMBXL1;
       
  1102     }
       
  1103 
       
  1104 // -----------------------------------------------------------------------------
       
  1105 // CPEEngineInfoImpl::VoiceMailBoxNumberLine2
       
  1106 // Gets the VoiceMailBoxNumber for line 2.
       
  1107 // (other items were commented in a header).
       
  1108 // -----------------------------------------------------------------------------
       
  1109 //
       
  1110 const TPEPhoneNumber& CPEEngineInfoImpl::VoiceMailBoxNumberLine2() const
       
  1111     {
       
  1112     return iBasicInfo.iVMBXNumbers.iVMBXL2;
       
  1113     }
       
  1114     
       
  1115 // -----------------------------------------------------------------------------
       
  1116 // CPEEngienInfo::DTMFVoiceMailBoxNumberLine1
       
  1117 // Gets the DTMFVoiceMailBoxNumber for line 1.
       
  1118 // (other items were commented in a header).
       
  1119 // -----------------------------------------------------------------------------
       
  1120 //
       
  1121 const TPEPhoneNumber& CPEEngineInfoImpl::DTMFVoiceMailBoxNumberLine1() const
       
  1122     {
       
  1123     return iBasicInfo.iVMBXNumbers.iDTMFVMBXL1;
       
  1124     }
       
  1125 
       
  1126 // -----------------------------------------------------------------------------
       
  1127 // CPEEngienInfo::DTMFVoiceMailBoxNumberLine2
       
  1128 // Gets the DTMFVoiceMailBoxNumber for line 2.
       
  1129 // -----------------------------------------------------------------------------
       
  1130 //
       
  1131 const TPEPhoneNumber& CPEEngineInfoImpl::DTMFVoiceMailBoxNumberLine2() const
       
  1132     {
       
  1133     return iBasicInfo.iVMBXNumbers.iDTMFVMBXL2;
       
  1134     }    
       
  1135 
       
  1136 // -----------------------------------------------------------------------------
       
  1137 // CPEEngineInfoImpl::SetAlertForGroup
       
  1138 // Set the group id's which are active to play ring tone
       
  1139 // -----------------------------------------------------------------------------
       
  1140 //
       
  1141 void CPEEngineInfoImpl::SetAlertForGroup(
       
  1142         const TArray< TContactItemId >& aAlertForGroup ) 
       
  1143     {
       
  1144     TInt errorCode( KErrNone );
       
  1145 
       
  1146     iAlertForGroup.Reset();
       
  1147     for ( TInt i = 0; i < aAlertForGroup.Count(); i++ )
       
  1148         {
       
  1149         errorCode = iAlertForGroup.Append( aAlertForGroup[ i ] );
       
  1150         TEFLOGSTRING3( 
       
  1151             KTAINT, 
       
  1152             "PE CPEEngineInfoImpl::SetAlertForGroup, index: %d, alert for: %d", 
       
  1153             i, 
       
  1154             aAlertForGroup[ i ] );
       
  1155         }
       
  1156     if ( errorCode != KErrNone )
       
  1157         {
       
  1158         TEFLOGSTRING2( KTAERROR,
       
  1159             "CPEENGINEINFOIMPL::SETALERTFORGROUP ! RARRAY::APPEND FAILED WITH EXIT CODE: &d",
       
  1160             errorCode );
       
  1161         iAlertForGroup.Reset();
       
  1162         }
       
  1163     }
       
  1164 
       
  1165 // -----------------------------------------------------------------------------
       
  1166 // CPEEngineInfoImpl::SetAudioMute
       
  1167 // Sets audio mute state of the phone to TPEBasicInfo-structure
       
  1168 // -----------------------------------------------------------------------------
       
  1169 //
       
  1170 void CPEEngineInfoImpl::SetAudioMute(
       
  1171         const TBool aAudioMute ) 
       
  1172     {
       
  1173     iBasicInfo.iAudioMute = aAudioMute; 
       
  1174     }
       
  1175 
       
  1176 // -----------------------------------------------------------------------------
       
  1177 // CPEEngineInfoImpl::SetAudioOutput
       
  1178 // Sets hands free mode of the phone to TPEBasicInfo-structure
       
  1179 // -----------------------------------------------------------------------------
       
  1180 //
       
  1181 void CPEEngineInfoImpl::SetAudioOutput(
       
  1182         const TPEAudioOutput aOutput,
       
  1183         const TPEAudioOutput aPreviousOutput,
       
  1184         const TBool aShowNote ) 
       
  1185     {
       
  1186     TEFLOGSTRING2( KTAINT, 
       
  1187         "PE CPEEngineInfoImpl::SetAudioOutput, output: %d", aOutput );
       
  1188     __ASSERT_ALWAYS( ( EPENotActive <= aOutput && 
       
  1189         aOutput <= EPETTY ), Panic( EPEPanicInvalidParameter ) );
       
  1190     iBasicInfo.iPhoneAudioRouteParameters.iAudioOutput = aOutput;
       
  1191     iBasicInfo.iPhoneAudioRouteParameters.iPreviousOutput = aPreviousOutput;
       
  1192     iBasicInfo.iPhoneAudioRouteParameters.iShowNote = aShowNote;
       
  1193     }
       
  1194 
       
  1195 // -----------------------------------------------------------------------------
       
  1196 // CPEEngineInfoImpl::SetAvailableAudioOutputs
       
  1197 // Sets hands free mode of the phone to TPEBasicInfo-structure
       
  1198 // -----------------------------------------------------------------------------
       
  1199 //
       
  1200 void CPEEngineInfoImpl::SetAvailableAudioOutputs(
       
  1201         const TArray<TPEAudioOutput>& aAvailableOutputs ) 
       
  1202     {
       
  1203     TEFLOGSTRING( KTAINT, "PE CPEEngineInfoImpl::SetAvailableAudioOutputs" );
       
  1204     // reset the array
       
  1205     iAvailableAudioOutputs.Reset();
       
  1206 
       
  1207     // set the available outputs
       
  1208     for (TInt j = 0; j < aAvailableOutputs.Count(); j++)
       
  1209         {
       
  1210         iAvailableAudioOutputs[j] = aAvailableOutputs[j];
       
  1211         TEFLOGSTRING3( 
       
  1212             KTAINT, 
       
  1213             "PE CPEEngineInfoImpl::SetAvailableAudioOutputs, index: %d, available: %d", 
       
  1214             j, 
       
  1215             aAvailableOutputs[j] );
       
  1216         }
       
  1217     TEFLOGSTRING( KTAINT, "PE CPEEngineInfoImpl::SetAvailableAudioOutputs:  Done" );    
       
  1218     }
       
  1219 
       
  1220 // -----------------------------------------------------------------------------
       
  1221 // CPEEngineInfoImpl::SetAudioOutputPreference
       
  1222 // Sets audio output preference to TPEBasicInfo-structure
       
  1223 // -----------------------------------------------------------------------------
       
  1224 //
       
  1225 void CPEEngineInfoImpl::SetAudioOutputPreference(
       
  1226         const TInt aOutputPreference )
       
  1227     {    
       
  1228     TEFLOGSTRING2( KTAINT, 
       
  1229         "PE CPEEngineInfoImpl::SetAudioOutputPreference, value: %d", 
       
  1230         aOutputPreference );    
       
  1231     __ASSERT_ALWAYS( !( aOutputPreference != EPSAudioPrivate && 
       
  1232         aOutputPreference != EPSAudioPublic ), Panic( EPEPanicInvalidParameter ) );
       
  1233     iBasicInfo.iAudioOutputPreference = aOutputPreference;
       
  1234     }
       
  1235 
       
  1236 // -----------------------------------------------------------------------------
       
  1237 // CPEEngineInfoImpl::SetAudioVolume
       
  1238 // Sets audio volume of the phone to TPEBasicInfo-structure
       
  1239 // -----------------------------------------------------------------------------
       
  1240 //
       
  1241 void CPEEngineInfoImpl::SetAudioVolume(
       
  1242         const TInt aAudioVolume )
       
  1243     {
       
  1244     TEFLOGSTRING2( KTAINT, 
       
  1245         "PE CPEEngineInfoImpl::SetAudioVolume, volume: %d", aAudioVolume );
       
  1246     iBasicInfo.iAudioVolume = aAudioVolume;
       
  1247     }
       
  1248     
       
  1249 // -----------------------------------------------------------------------------
       
  1250 // CPEEngineInfoImpl::SetCallALSLine
       
  1251 // Sets the alsline value to the TPECallInfo structure.
       
  1252 // -----------------------------------------------------------------------------
       
  1253 //
       
  1254 void CPEEngineInfoImpl::SetCallALSLine( 
       
  1255         const CCCECallParameters::TCCELineType& aALSLine,
       
  1256         const TInt aCallId )
       
  1257     {
       
  1258     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1259     __ASSERT_ALWAYS( ( CCCECallParameters::ECCELineTypePrimary <= aALSLine && aALSLine <= CCCECallParameters::ECCELineTypeAux ),
       
  1260         Panic( EPEPanicInvalidParameter ) );
       
  1261     iCurrentCalls[ aCallId ]->SetAlsLine( aALSLine );
       
  1262     TEFLOGSTRING3( KTAINT, 
       
  1263         "PE CPEEngineInfoImpl::SetCallALSLine: line: %d, call id: %d", 
       
  1264         iCurrentCalls[ aCallId ]->AlsLine(), 
       
  1265         aCallId );
       
  1266     }    
       
  1267 
       
  1268 // -----------------------------------------------------------------------------
       
  1269 // CPEEngineInfoImpl::SetCallDuration
       
  1270 // Sets call duration of the last call to Idle to TPEBasicInfo-structure
       
  1271 // -----------------------------------------------------------------------------
       
  1272 //
       
  1273 void CPEEngineInfoImpl::SetCallDuration(
       
  1274         const TInt& aCallDuration ) 
       
  1275     {
       
  1276     iBasicInfo.iLastCallDuration = aCallDuration; 
       
  1277     }
       
  1278 	
       
  1279 // -----------------------------------------------------------------------------
       
  1280 // CPEEngineInfoImpl::SetDtmfPostFix
       
  1281 // Sets dtmf postfix value to TPEBasicInfo-structure
       
  1282 // -----------------------------------------------------------------------------
       
  1283 //
       
  1284 void CPEEngineInfoImpl::SetDtmfPostFix( 
       
  1285         const TPEDtmfString& aDtmfPostFix,
       
  1286         const TInt aCallId )
       
  1287     {
       
  1288     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1289     __ASSERT_DEBUG( !( aDtmfPostFix.Length() > KPEDtmfMaxLength ),
       
  1290             Panic( EPEPanicInvalidParameter ) );
       
  1291     iCurrentCalls[ aCallId ]->SetDtmfPostFix( aDtmfPostFix );
       
  1292     }
       
  1293 
       
  1294 // -----------------------------------------------------------------------------
       
  1295 // CPEEngineInfoImpl::SetDtmfString
       
  1296 // Sets dtmf string value to TPEBasicInfo-structure
       
  1297 // -----------------------------------------------------------------------------
       
  1298 //
       
  1299 void CPEEngineInfoImpl::SetDtmfString(
       
  1300         const TPEDtmfString& aDtmfString ) 
       
  1301     {
       
  1302     __ASSERT_DEBUG( !( aDtmfString.Length() > KPEDtmfMaxLength ),
       
  1303         Panic( EPEPanicInvalidParameter ) );
       
  1304     iBasicInfo.iDtmfString = aDtmfString; 
       
  1305     }
       
  1306 // -----------------------------------------------------------------------------
       
  1307 // CPEEngineInfoImpl::SetErrorCode
       
  1308 // Sets error code of the phone to TPEBasicInfo-structure
       
  1309 // -----------------------------------------------------------------------------
       
  1310 //
       
  1311 void CPEEngineInfoImpl::SetErrorCode(
       
  1312         const TInt aErrorCode ) 
       
  1313     {
       
  1314     iBasicInfo.iErrorInfo.iErrorCode = aErrorCode; 
       
  1315     }
       
  1316 
       
  1317 // -----------------------------------------------------------------------------
       
  1318 // CPEEngineInfoImpl::SetInbandTone
       
  1319 // Sets correct inband tone for specific call state transition or error
       
  1320 // -----------------------------------------------------------------------------
       
  1321 //
       
  1322 void CPEEngineInfoImpl::SetInbandTone( const TCCPTone aTone ) 
       
  1323     {
       
  1324     iBasicInfo.iInbandTone = aTone; 
       
  1325     }
       
  1326 
       
  1327 // -----------------------------------------------------------------------------
       
  1328 // CPEEngineInfoImpl::SetKeypadVolume
       
  1329 // Sets keypad volume of the phone to TPEBasicInfo-structure
       
  1330 // -----------------------------------------------------------------------------
       
  1331 //
       
  1332 void CPEEngineInfoImpl::SetKeypadVolume(
       
  1333         const TInt aKeypadVolume ) 
       
  1334     {
       
  1335     iBasicInfo.iKeypadVolume = aKeypadVolume; 
       
  1336     }
       
  1337 
       
  1338 // -----------------------------------------------------------------------------
       
  1339 // CPEEngineInfoImpl::SetLifeTimerData
       
  1340 // Sets lifetimer data of the phone to TPELifeTimeData-structure
       
  1341 // -----------------------------------------------------------------------------
       
  1342 //
       
  1343 void CPEEngineInfoImpl::SetLifeTimerData( 
       
  1344         TCCPLifeTimeDataPckg& aPckg )
       
  1345     {
       
  1346     iBasicInfo.iLifeTimeData.iHours = aPckg().iHours;
       
  1347     iBasicInfo.iLifeTimeData.iMinutes = aPckg().iMinutes;
       
  1348     }
       
  1349 
       
  1350 // -----------------------------------------------------------------------------
       
  1351 // CPEEngineInfoImpl::SetNetworkRegistrationStatus
       
  1352 // Sets network registration status to TPEBasicInfo-structure
       
  1353 // -----------------------------------------------------------------------------
       
  1354 //
       
  1355 void CPEEngineInfoImpl::SetNetworkRegistrationStatus(
       
  1356         const TNWNetworkRegistrationStatus& aRegistrationStatus ) 
       
  1357     {
       
  1358     __ASSERT_ALWAYS( ( ENWStatusRegistrationUnknown <= aRegistrationStatus &&
       
  1359         aRegistrationStatus <= ENWStatusRegisteredRoaming ), Panic( EPEPanicInvalidParameter ) );
       
  1360     iBasicInfo.iNetworkRegistrationStatus = aRegistrationStatus;
       
  1361     TEFLOGSTRING2( KTAINT, 
       
  1362         "PE CPEEngineInfoImpl::SetNetworkRegistrationStatus, iNetworkRegistrationStatus: %d", 
       
  1363         iBasicInfo.iNetworkRegistrationStatus );
       
  1364     }
       
  1365 
       
  1366 // -----------------------------------------------------------------------------
       
  1367 // CPEEngineInfoImpl::SetPersonalToneStatus
       
  1368 // Sets personal tone status of the phones profile settings to TPEBasicInfo-structure
       
  1369 // -----------------------------------------------------------------------------
       
  1370 //
       
  1371 void CPEEngineInfoImpl::SetPersonalToneStatus( 
       
  1372         const TInt& aPersonalToneStatus ) 
       
  1373     {
       
  1374     iBasicInfo.iPersonalToneStatus = aPersonalToneStatus; 
       
  1375     }
       
  1376 
       
  1377 // -----------------------------------------------------------------------------
       
  1378 // CPEEngineInfoImpl::SetPhoneIdentityParameters
       
  1379 // Sets phone number to TPECallCommandInfo-structure
       
  1380 // -----------------------------------------------------------------------------
       
  1381 //
       
  1382 void CPEEngineInfoImpl::SetPhoneIdentityParameters(
       
  1383         const TPEPhoneIdentityParameters& aPhoneIdentityParameters ) 
       
  1384     { 
       
  1385     iBasicInfo.iPhoneIdentityParameters = aPhoneIdentityParameters; 
       
  1386     }
       
  1387 
       
  1388 // -----------------------------------------------------------------------------
       
  1389 // CPEEngineInfoImpl::SetPhoneNumberIsServiceCode
       
  1390 // Sets phone number parsing result
       
  1391 // -----------------------------------------------------------------------------
       
  1392 //
       
  1393 void CPEEngineInfoImpl::SetPhoneNumberIsServiceCode( 
       
  1394     const TBool& aServiceCode )
       
  1395     {
       
  1396     iBasicInfo.iPhoneNumberIsServiceCode = aServiceCode;
       
  1397     }
       
  1398 
       
  1399 // -----------------------------------------------------------------------------
       
  1400 // CPEEngineInfoImpl::SetCallOriginCommand
       
  1401 // Sets call origin for the next call attempt
       
  1402 // -----------------------------------------------------------------------------
       
  1403 //
       
  1404 void CPEEngineInfoImpl::SetCallOriginCommand( const TPECallOrigin& aOrigin )
       
  1405 	{
       
  1406 	iCallCommandInfo.iCallOrigin = aOrigin;
       
  1407 	}
       
  1408 
       
  1409 // -----------------------------------------------------------------------------
       
  1410 // CPEEngineInfoImpl::SetProfileId
       
  1411 // Sets profile id to TPEBasicInfo-structure
       
  1412 // (other items were commented in a header).
       
  1413 // -----------------------------------------------------------------------------
       
  1414 //
       
  1415 void CPEEngineInfoImpl::SetProfileId(
       
  1416         const TInt aProfileId ) 
       
  1417     {
       
  1418     iBasicInfo.iProfileId = aProfileId; 
       
  1419     }
       
  1420 
       
  1421 // -----------------------------------------------------------------------------
       
  1422 // CPEEngineInfoImpl::SetProfileName
       
  1423 // Sets profile name to TPEBasicInfo-structure
       
  1424 // (other items were commented in a header).
       
  1425 // -----------------------------------------------------------------------------
       
  1426 //
       
  1427 void CPEEngineInfoImpl::SetProfileName(
       
  1428         const TPEProfileName& aProfileName ) 
       
  1429     {
       
  1430     __ASSERT_DEBUG( !( aProfileName.Length() > KPEProfileNameLength ), Panic( EPEPanicInvalidParameter ) );
       
  1431     iBasicInfo.iProfileName = aProfileName; 
       
  1432     }
       
  1433 
       
  1434 // -----------------------------------------------------------------------------
       
  1435 // CPEEngineInfoImpl::SetRingingTone1
       
  1436 // Sets ringing type to TPEBasicInfo-structure
       
  1437 // (other items were commented in a header).
       
  1438 // -----------------------------------------------------------------------------
       
  1439 //
       
  1440 void CPEEngineInfoImpl::SetRingingTone1(
       
  1441         const TPEContactFileName& aRingingToneName )
       
  1442     {
       
  1443     __ASSERT_DEBUG( !( aRingingToneName.Length() > KMaxFileName ), 
       
  1444         Panic( EPEPanicInvalidParameter ) );
       
  1445     iBasicInfo.iRingingToneName1 = aRingingToneName; 
       
  1446     }
       
  1447     
       
  1448 // -----------------------------------------------------------------------------
       
  1449 // CPEEngineInfoImpl::SetRingingTone2
       
  1450 // Sets ringing type to TPEBasicInfo-structure
       
  1451 // (other items were commented in a header).
       
  1452 // -----------------------------------------------------------------------------
       
  1453 //
       
  1454 void CPEEngineInfoImpl::SetRingingTone2( 
       
  1455         const TPEContactFileName& aRingingToneName )
       
  1456     {
       
  1457     __ASSERT_DEBUG( !( aRingingToneName.Length() > KMaxFileName ), 
       
  1458         Panic( EPEPanicInvalidParameter ) );
       
  1459     iBasicInfo.iRingingToneName2 = aRingingToneName; 
       
  1460     }
       
  1461 
       
  1462 // -----------------------------------------------------------------------------
       
  1463 // CPEEngineInfoImpl::SetVideoCallRingingTone
       
  1464 // Sets video call ringing tone name to TPEBasicInfo-structure
       
  1465 // (other items were commented in a header).
       
  1466 // -----------------------------------------------------------------------------
       
  1467 //
       
  1468 void CPEEngineInfoImpl::SetVideoCallRingingTone( 
       
  1469         const TPEContactFileName& aRingingToneName )
       
  1470     {
       
  1471     __ASSERT_DEBUG( !( aRingingToneName.Length() > KMaxFileName ), 
       
  1472         Panic( EPEPanicInvalidParameter ) );
       
  1473     iBasicInfo.iVideoCallRingingTone = aRingingToneName; 
       
  1474     }
       
  1475     
       
  1476 // -----------------------------------------------------------------------------
       
  1477 // CPEEngineInfoImpl::SetRingingType
       
  1478 // Sets ringing type to TPEBasicInfo-structure
       
  1479 // (other items were commented in a header).
       
  1480 // -----------------------------------------------------------------------------
       
  1481 //
       
  1482 void CPEEngineInfoImpl::SetRingingType(
       
  1483         const TProfileRingingType& aRingingType )
       
  1484     {
       
  1485     __ASSERT_ALWAYS( ( EProfileRingingTypeRinging <= aRingingType && 
       
  1486         aRingingType <= EProfileRingingTypeSilent ), Panic( EPEPanicInvalidParameter ) );
       
  1487     iBasicInfo.iRingingType = aRingingType; 
       
  1488     }
       
  1489 
       
  1490 // -----------------------------------------------------------------------------
       
  1491 // CPEEngineInfoImpl::SetRingingVolume
       
  1492 // Sets ringing volume to TPEBasicInfo-structure
       
  1493 // (other items were commented in a header).
       
  1494 // -----------------------------------------------------------------------------
       
  1495 //
       
  1496 void CPEEngineInfoImpl::SetRingingVolume(
       
  1497         const TInt& aRingingVolume )
       
  1498     {
       
  1499     iBasicInfo.iRingingVolume = aRingingVolume; 
       
  1500     }
       
  1501 
       
  1502 // -----------------------------------------------------------------------------
       
  1503 // CPEEngineInfoImpl::SetTextToSpeech
       
  1504 // Sets text-to-speech of the phone to TPEBasicInfo-structure
       
  1505 // (other items were commented in a header).
       
  1506 // -----------------------------------------------------------------------------
       
  1507 //
       
  1508 void CPEEngineInfoImpl::SetTextToSpeech( 
       
  1509     const TBool aTextToSpeech )
       
  1510     {
       
  1511     iBasicInfo.iTextToSpeech = aTextToSpeech;
       
  1512     }
       
  1513     
       
  1514 // -----------------------------------------------------------------------------
       
  1515 // CPEEngineInfoImpl::SetTwoDigitSupportStatus
       
  1516 // Sets two digit support status of the phone to TPEBasicInfo-structure
       
  1517 // (other items were commented in a header).
       
  1518 // -----------------------------------------------------------------------------
       
  1519 //
       
  1520 void CPEEngineInfoImpl::SetTwoDigitSupportStatus( 
       
  1521     const TBool aTwoDigitSupportStatus )
       
  1522     {
       
  1523     iBasicInfo.iTwoDigitSupportStatus = aTwoDigitSupportStatus;
       
  1524     }
       
  1525     
       
  1526 // -----------------------------------------------------------------------------
       
  1527 // CPEEngineInfoImpl::SetCallSecureStatus
       
  1528 // Sets Secure status to call info
       
  1529 // -----------------------------------------------------------------------------
       
  1530 //
       
  1531 void CPEEngineInfoImpl::SetCallSecureStatus( 
       
  1532     const TBool aSecureStatus, 
       
  1533     const TInt aCallId )
       
  1534     {
       
  1535     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1536     iCurrentCalls[ aCallId ]->SetSecureStatus( aSecureStatus );
       
  1537     TEFLOGSTRING3( KTAINT, 
       
  1538         "PE CPEEngineInfoImpl::SetCallSecureStatus, iSecureStatus: %d, call id: %d", 
       
  1539         iCurrentCalls[ aCallId ]->SecureStatus(), 
       
  1540         aCallId );
       
  1541     }  
       
  1542 
       
  1543 // -----------------------------------------------------------------------------
       
  1544 // CPEEngineInfoImpl::SetSecureSpecified
       
  1545 // Sets Secure status to call info
       
  1546 // -----------------------------------------------------------------------------
       
  1547 //
       
  1548 void CPEEngineInfoImpl::SetSecureSpecified( 
       
  1549     const TBool aSecureSpecified )
       
  1550     {
       
  1551     iBasicInfo.iSecureSpecified = aSecureSpecified;
       
  1552     }  
       
  1553 
       
  1554 // -----------------------------------------------------------------------------
       
  1555 // CPEEngienInfo::SetDTMFVoiceMailBoxNumberLine1
       
  1556 // Sets DTMFVoiceMailBoxNumber for Line 1 information from TPEBasicInfo-structure
       
  1557 // (other items were commented in a header).
       
  1558 // -----------------------------------------------------------------------------
       
  1559 //
       
  1560 void CPEEngineInfoImpl::SetDTMFVoiceMailBoxNumberLine1( 
       
  1561     const TDesC& aDTMFVoiceMailBoxNumberLine1 ) 
       
  1562     { 
       
  1563     __ASSERT_DEBUG( !( aDTMFVoiceMailBoxNumberLine1.Length() 
       
  1564         > KPEPhoneNumberMaxLength ), Panic( EPEPanicInvalidParameter ) );
       
  1565     iBasicInfo.iVMBXNumbers.iDTMFVMBXL1 = aDTMFVoiceMailBoxNumberLine1; 
       
  1566     }
       
  1567 
       
  1568 // -----------------------------------------------------------------------------
       
  1569 // CPEEngienInfo::SetDTMFVoiceMailBoxNumberLine2
       
  1570 // Sets DTMFVoiceMailBoxNumber for Line 2 information from 
       
  1571 // TPEBasicInfo-structure
       
  1572 // -----------------------------------------------------------------------------
       
  1573 //
       
  1574 void CPEEngineInfoImpl::SetDTMFVoiceMailBoxNumberLine2( 
       
  1575     const TDesC& aDTMFVoiceMailBoxNumberLine2 )
       
  1576     {
       
  1577     __ASSERT_DEBUG( !( aDTMFVoiceMailBoxNumberLine2.Length() 
       
  1578         > KPEPhoneNumberMaxLength ), Panic( EPEPanicInvalidParameter ) );
       
  1579     iBasicInfo.iVMBXNumbers.iDTMFVMBXL2 = aDTMFVoiceMailBoxNumberLine2; 
       
  1580     }
       
  1581     
       
  1582 // -----------------------------------------------------------------------------
       
  1583 // CPEEngienInfo::SetVoiceMailBoxNumberLine1
       
  1584 // Gets VoiceMailBoxNumber for Line 1 information from TPEBasicInfo-structure
       
  1585 // (other items were commented in a header).
       
  1586 // -----------------------------------------------------------------------------
       
  1587 //
       
  1588 void CPEEngineInfoImpl::SetVoiceMailBoxNumberLine1( 
       
  1589     const TDesC& aVoiceMailBoxNumberLine1 ) 
       
  1590     {
       
  1591     __ASSERT_DEBUG( !( aVoiceMailBoxNumberLine1.Length() 
       
  1592         > KPEPhoneNumberMaxLength ), Panic( EPEPanicInvalidParameter ) );
       
  1593     iBasicInfo.iVMBXNumbers.iVMBXL1 = aVoiceMailBoxNumberLine1; 
       
  1594     }
       
  1595 
       
  1596 // -----------------------------------------------------------------------------
       
  1597 // CPEEngienInfo::SetVoiceMailBoxNumberLine2
       
  1598 // Gets VoiceMailBoxNumber for Line 2 information from TPEBasicInfo-structure
       
  1599 // (other items were commented in a header).
       
  1600 // -----------------------------------------------------------------------------
       
  1601 //
       
  1602 void CPEEngineInfoImpl::SetVoiceMailBoxNumberLine2( 
       
  1603     const TDesC& aVoiceMailBoxNumberLine2 )
       
  1604     {
       
  1605     __ASSERT_DEBUG( !( aVoiceMailBoxNumberLine2.Length() 
       
  1606         > KPEPhoneNumberMaxLength ), Panic( EPEPanicInvalidParameter ) );
       
  1607     iBasicInfo.iVMBXNumbers.iVMBXL2 = aVoiceMailBoxNumberLine2; 
       
  1608     }
       
  1609     
       
  1610 // -----------------------------------------------------------------------------
       
  1611 // CPEEngineInfoImpl::SetLogForcedCopletion
       
  1612 // Set the log forced completion indicator.
       
  1613 // (other items were commented in a header).
       
  1614 // -----------------------------------------------------------------------------
       
  1615 //
       
  1616 void CPEEngineInfoImpl::SetLogForcedCompletion(
       
  1617     const TBool aForcedCompletion,  
       
  1618     const TInt aCallId )
       
  1619     {
       
  1620     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1621     iCurrentCalls[ aCallId ]->SetLogForcedCompletion( aForcedCompletion );
       
  1622     }    
       
  1623 
       
  1624 // -----------------------------------------------------------------------------
       
  1625 // CPEEngineInfoImpl::GetLogForcedCompletion
       
  1626 // Gets the log forced completion indicator
       
  1627 // (other items were commented in a header).
       
  1628 // -----------------------------------------------------------------------------
       
  1629 //
       
  1630 TBool CPEEngineInfoImpl::LogForcedCompletion( 
       
  1631     const TInt aCallId ) const
       
  1632     {
       
  1633     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1634     return iCurrentCalls[ aCallId ]->LogForcedCompletion();
       
  1635     }
       
  1636    
       
  1637 // -----------------------------------------------------------------------------
       
  1638 // CPEEngineInfoImpl::SetPhoneNumber
       
  1639 // Sets the phone number to the TPECallCommandInfo structure.
       
  1640 // (other items were commented in a header).
       
  1641 // -----------------------------------------------------------------------------
       
  1642 //
       
  1643 void CPEEngineInfoImpl::SetWholeOutgoingPhoneNumber( 
       
  1644         const TPEPhoneNumber& aPhoneNumber, 
       
  1645         const TInt aCallId )
       
  1646     {
       
  1647     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1648     __ASSERT_DEBUG( !( aPhoneNumber.Length() > KPEPhoneNumberMaxLength ),
       
  1649         Panic( EPEPanicInvalidParameter ) );
       
  1650     iCurrentCalls[ aCallId ]->SetWholeOutgoingPhoneNumber( aPhoneNumber );
       
  1651     TEFLOGSTRING3( KTAINT, 
       
  1652         "PE CPEEngineInfoImpl::SetWholeOutgoingPhoneNumber: phone number: '%S', call id: %d"
       
  1653         , &iCurrentCalls[ aCallId ]->WholeOutgoingPhoneNumber(), aCallId );
       
  1654     }
       
  1655     
       
  1656 // -----------------------------------------------------------------------------
       
  1657 // CPEEngineInfoImpl::PhoneNumber
       
  1658 // Return the phone number from the TPECallCommandInfo structure.
       
  1659 // (other items were commented in a header).
       
  1660 // -----------------------------------------------------------------------------
       
  1661 //
       
  1662 const TPEPhoneNumber& CPEEngineInfoImpl::WholeOutgoingPhoneNumber( 
       
  1663         const TInt aCallId ) const
       
  1664     {
       
  1665     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1666     return iCurrentCalls[ aCallId ]->WholeOutgoingPhoneNumber();
       
  1667     }
       
  1668                 
       
  1669 // -----------------------------------------------------------------------------
       
  1670 // CPEEngineInfoImpl::ServiceIdCommand
       
  1671 // Return the Service Id from the TPECallCommandInfo structure.
       
  1672 // -----------------------------------------------------------------------------
       
  1673 //
       
  1674 TUint32 CPEEngineInfoImpl::ServiceIdCommand() const
       
  1675     {
       
  1676     return iCallCommandInfo.iServiceId; 
       
  1677     } 
       
  1678 
       
  1679 // -----------------------------------------------------------------------------
       
  1680 // CPEEngineInfoImpl::SetServiceIdCommand
       
  1681 // Set the Service Id to the TPECallCommandInfo structure.
       
  1682 // -----------------------------------------------------------------------------
       
  1683 //
       
  1684 void CPEEngineInfoImpl::SetServiceIdCommand( TUint32 aServiceId )
       
  1685     {
       
  1686     iCallCommandInfo.iServiceId = aServiceId; 
       
  1687     }
       
  1688                 
       
  1689 // -----------------------------------------------------------------------------
       
  1690 // CPEEngineInfoImpl::ServiceId
       
  1691 // Return the Service Id from the TPECallInfo structure.
       
  1692 // -----------------------------------------------------------------------------
       
  1693 //
       
  1694 TUint32 CPEEngineInfoImpl::ServiceId( const TInt aCallId ) const
       
  1695     {
       
  1696     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1697     return iCurrentCalls[ aCallId ]->CallServiceId(); 
       
  1698     } 
       
  1699 
       
  1700 // -----------------------------------------------------------------------------
       
  1701 // CPEEngineInfoImpl::SetServiceId
       
  1702 // Set the Service Id to the TPECallInfo structure.
       
  1703 // -----------------------------------------------------------------------------
       
  1704 //
       
  1705 void CPEEngineInfoImpl::SetServiceId( const TInt aCallId, TUint32 aServiceId )
       
  1706     {
       
  1707     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1708     iCurrentCalls[ aCallId ]->SetCallServiceId( aServiceId ); 
       
  1709     }
       
  1710     
       
  1711 // -----------------------------------------------------------------------------
       
  1712 // CPEEngineInfoImpl::ActiveForwardingInfo
       
  1713 // Gets active forward info from the TPEBasicInfo structure. 
       
  1714 // (other items were commented in a header).
       
  1715 // -----------------------------------------------------------------------------
       
  1716 //
       
  1717 const TPEActiveForwardInfo& CPEEngineInfoImpl::ActiveForwardingInfo() const
       
  1718     {
       
  1719     return iBasicInfo.iActiveForward;
       
  1720     }
       
  1721 
       
  1722 // -----------------------------------------------------------------------------
       
  1723 // CPEEngineInfoImpl::BarringInfo
       
  1724 // Gets the call barring information.
       
  1725 // (other items were commented in a header).
       
  1726 // -----------------------------------------------------------------------------
       
  1727 //
       
  1728 const TPEBarringInfo& CPEEngineInfoImpl::BarringInfo() const
       
  1729     {
       
  1730     return iBasicInfo.iBarringInfo;
       
  1731     }
       
  1732 
       
  1733 // -----------------------------------------------------------------------------
       
  1734 // CPEEngineInfoImpl::CallConference
       
  1735 // Gets the call's conference value.
       
  1736 // (other items were commented in a header).
       
  1737 // -----------------------------------------------------------------------------
       
  1738 //
       
  1739 TInt CPEEngineInfoImpl::CallConference( const TInt aCallId ) const
       
  1740     {
       
  1741     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1742     return iCurrentCalls[ aCallId ]->Conference();
       
  1743     }
       
  1744 
       
  1745 // -----------------------------------------------------------------------------
       
  1746 // CPEEngineInfoImpl::CallControlCaps
       
  1747 // Gets the call control caps
       
  1748 // (other items were commented in a header).
       
  1749 // -----------------------------------------------------------------------------
       
  1750 //
       
  1751 TPECallControlCaps CPEEngineInfoImpl::CallControlCaps( const TInt aCallId ) const
       
  1752     {
       
  1753     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1754     return iCurrentCalls[ aCallId ]->CallControlCaps();
       
  1755     }
       
  1756 
       
  1757 // -----------------------------------------------------------------------------
       
  1758 // CPEEngineInfoImpl::CallForwarded
       
  1759 // Gets the call forwarded value. 
       
  1760 // (other items were commented in a header).
       
  1761 // -----------------------------------------------------------------------------
       
  1762 //
       
  1763 TBool CPEEngineInfoImpl::CallForwarded( const TInt aCallId ) const
       
  1764     {
       
  1765     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1766     return iCurrentCalls[ aCallId ]->Forwarded();
       
  1767     }
       
  1768 
       
  1769 // -----------------------------------------------------------------------------
       
  1770 // CPEEngineInfoImpl::CallService
       
  1771 // Gets Service value.
       
  1772 // (other items were commented in a header).
       
  1773 // -----------------------------------------------------------------------------
       
  1774 //
       
  1775 RMobilePhone::TMobileService CPEEngineInfoImpl::CallService( const TInt aCallId ) const
       
  1776     {
       
  1777     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1778     return iCurrentCalls[ aCallId ]->Service();
       
  1779     }
       
  1780 
       
  1781 // -----------------------------------------------------------------------------
       
  1782 // CPEEngineInfoImpl::ConferenceCallCaps
       
  1783 // Gets Conference call capabilities.
       
  1784 // (other items were commented in a header).
       
  1785 // -----------------------------------------------------------------------------
       
  1786 //
       
  1787 TUint32 CPEEngineInfoImpl::ConferenceCallCaps( const TInt aCallId ) const
       
  1788     {
       
  1789     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1790     return iCurrentCalls[ aCallId ]->ConferenceCaps();
       
  1791     }
       
  1792 
       
  1793 // -----------------------------------------------------------------------------
       
  1794 // CPEEngineInfoImpl::ConferenceMemberName 
       
  1795 // Gets added or removed Conference members TName information.
       
  1796 // (other items were commented in a header).
       
  1797 // -----------------------------------------------------------------------------
       
  1798 //
       
  1799 const TName& CPEEngineInfoImpl::ConferenceMemberName( const TInt aCallId ) const
       
  1800     {
       
  1801     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1802     return iCurrentCalls[ aCallId ]->ConferenceMemberName();
       
  1803     }
       
  1804 // -----------------------------------------------------------------------------
       
  1805 // CPEEngineInfoImpl::IsConferenceMemberId 
       
  1806 // Gets added or removed Conference members TName information.
       
  1807 // (other items were commented in a header).
       
  1808 // -----------------------------------------------------------------------------
       
  1809 //
       
  1810 TInt CPEEngineInfoImpl::IsConferenceMemberId( const TInt aCallId ) const
       
  1811     {
       
  1812     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1813     return iCurrentCalls[ aCallId ]->ConferenceMemberId();
       
  1814     }
       
  1815 
       
  1816 // -----------------------------------------------------------------------------
       
  1817 // CPEEngineInfoImpl::EmergencyNumber
       
  1818 // Gets emergency number for checking.
       
  1819 // (other items were commented in a header).
       
  1820 // -----------------------------------------------------------------------------
       
  1821 //
       
  1822 const TPEPhoneNumber& CPEEngineInfoImpl::EmergencyNumber() const
       
  1823     {
       
  1824     return iCallCommandInfo.iEmergencyNumber;
       
  1825     }
       
  1826 
       
  1827 // -----------------------------------------------------------------------------
       
  1828 // CPEEngineInfoImpl::NumberOfConferenceMembers
       
  1829 // Gets number of conference members involved in conference call.
       
  1830 // (other items were commented in a header).
       
  1831 // -----------------------------------------------------------------------------
       
  1832 //
       
  1833 TInt CPEEngineInfoImpl::NumberOfConferenceMembers( const TInt aCallId ) const
       
  1834     {
       
  1835     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1836     return iCurrentCalls[ aCallId ]->NumberOfConferenceMembers();
       
  1837     }
       
  1838 
       
  1839 // -----------------------------------------------------------------------------
       
  1840 // CPEEngineInfoImpl::SimState 
       
  1841 // Gets Sim state from the TPEBasicInfo structure.
       
  1842 // (other items were commented in a header).
       
  1843 // -----------------------------------------------------------------------------
       
  1844 //
       
  1845 const TPESimState& CPEEngineInfoImpl::SimState() const
       
  1846     {
       
  1847     return iBasicInfo.iSimState;
       
  1848     }
       
  1849 
       
  1850 // -----------------------------------------------------------------------------
       
  1851 // CPEEngineInfoImpl::SecureSpecified
       
  1852 // Gets secure specified status 
       
  1853 // -----------------------------------------------------------------------------
       
  1854 //
       
  1855 TBool CPEEngineInfoImpl::SecureSpecified( ) const
       
  1856     {
       
  1857     return iBasicInfo.iSecureSpecified;
       
  1858     }
       
  1859 
       
  1860 // -----------------------------------------------------------------------------
       
  1861 // CPEEngineInfoImpl::SSCommandInfo
       
  1862 // Gets the last suplementary services string command information.
       
  1863 // (other items were commented in a header).
       
  1864 // -----------------------------------------------------------------------------
       
  1865 //
       
  1866 const TPESSCommandInfo& CPEEngineInfoImpl::SSCommandInfo() const
       
  1867     {
       
  1868     return iBasicInfo.iSSCommandInfo;
       
  1869     }
       
  1870 
       
  1871 // -----------------------------------------------------------------------------
       
  1872 // CPEEngineInfoImpl::ResetCallInfo
       
  1873 // Resets TPECallInfo structure.
       
  1874 // (other items were commented in a header).
       
  1875 // -----------------------------------------------------------------------------
       
  1876 //
       
  1877 void CPEEngineInfoImpl::ResetCallInfo( const TInt aCallId )
       
  1878     {
       
  1879     TEFLOGSTRING2( KTAINT, 
       
  1880         "PE CPEEngineInfoImpl::ResetCallInfo CallId %d", aCallId );
       
  1881     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1882 
       
  1883     iCurrentCalls[aCallId]->Reset( CallIdCheck::IsConference( aCallId ) );
       
  1884     
       
  1885     if ( iRemoteInfo->Count() &&       // Check that array is not empty
       
  1886          ( *iRemoteInfo )[aCallId ]     // Check that there is content in this index
       
  1887        )
       
  1888         {
       
  1889         ( *iRemoteInfo )[aCallId ]->ResetRemoteInfo();
       
  1890         }
       
  1891     }
       
  1892 
       
  1893 // -----------------------------------------------------------------------------
       
  1894 // CPEEngineInfoImpl::SetCallConference
       
  1895 // Sets the conference value to the TPECallInfo structure.
       
  1896 // (other items were commented in a header).
       
  1897 // -----------------------------------------------------------------------------
       
  1898 //
       
  1899 void CPEEngineInfoImpl::SetCallConference( const TInt aConference, const TInt aCallId )
       
  1900     {
       
  1901     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicIllegalCommand ) );
       
  1902     iCurrentCalls[ aCallId ]->SetConference( aConference );
       
  1903     }
       
  1904 
       
  1905 // -----------------------------------------------------------------------------
       
  1906 // CPEEngineInfoImpl::SetCallControlCaps
       
  1907 // Sets the call control caps to the TPECallInfo structure.
       
  1908 // (other items were commented in a header).
       
  1909 // -----------------------------------------------------------------------------
       
  1910 //
       
  1911 void CPEEngineInfoImpl::SetCallControlCaps( const TPECallControlCaps& aCallControlCaps,
       
  1912         const TInt aCallId )
       
  1913     {
       
  1914     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicIllegalCommand ) );
       
  1915     iCurrentCalls[ aCallId ]->SetCallControlCaps( aCallControlCaps );
       
  1916     }
       
  1917 
       
  1918 // -----------------------------------------------------------------------------
       
  1919 // CPEEngineInfoImpl::SetCallForwarded
       
  1920 // Sets the forwarded value to the TPECallInfo structure.
       
  1921 // (other items were commented in a header).
       
  1922 // -----------------------------------------------------------------------------
       
  1923 //
       
  1924 void CPEEngineInfoImpl::SetCallForwarded( const TBool aCallForwarded, const TInt aCallId )
       
  1925     {
       
  1926     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1927     iCurrentCalls[ aCallId ]->SetForwarded( aCallForwarded );
       
  1928     }
       
  1929 
       
  1930 // -----------------------------------------------------------------------------
       
  1931 // CPEEngineInfoImpl::SetCallService
       
  1932 // Sets the call service to the TPECallInfo structure.
       
  1933 // (other items were commented in a header).
       
  1934 // -----------------------------------------------------------------------------
       
  1935 //
       
  1936 void CPEEngineInfoImpl::SetCallService( const RMobilePhone::TMobileService& aCallService,
       
  1937         const TInt aCallId )
       
  1938     {
       
  1939     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1940     iCurrentCalls[ aCallId ]->SetService( aCallService );
       
  1941     }
       
  1942 
       
  1943 // -----------------------------------------------------------------------------
       
  1944 // CPEEngineInfoImpl::SetConferenceCallCaps
       
  1945 // Sets the conference call capabilities to the TPECallInfo structure.
       
  1946 // (other items were commented in a header).
       
  1947 // -----------------------------------------------------------------------------
       
  1948 //
       
  1949 void CPEEngineInfoImpl::SetConferenceCallCaps( const TUint32 aCaps, const TInt aCallId )
       
  1950     {
       
  1951     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1952     iCurrentCalls[ aCallId ]->SetConferenceCaps( aCaps );
       
  1953     }
       
  1954 
       
  1955 // -----------------------------------------------------------------------------
       
  1956 // CPEEngineInfoImpl::SetConferenceMemberInfo
       
  1957 // Sets the added or removed conference members TName information to the TPECallInfo structure.
       
  1958 // (other items were commented in a header).
       
  1959 // -----------------------------------------------------------------------------
       
  1960 //
       
  1961 void CPEEngineInfoImpl::SetConferenceMemberInfo( const TName& aConferenceMemberName, 
       
  1962         const TInt aConferenceMemberCallId, const TInt aCallId  )
       
  1963     {
       
  1964     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1965     iCurrentCalls[ aCallId ]->SetConferenceMemberName( aConferenceMemberName );
       
  1966     iCurrentCalls[ aCallId ]->SetConferenceMemberId( aConferenceMemberCallId ); 
       
  1967     }
       
  1968 
       
  1969 // -----------------------------------------------------------------------------
       
  1970 // CPEEngineInfoImpl::SetEmergencyNumber
       
  1971 // Sets the emergency numbers of the phone to the TPEBasicInfo structure.
       
  1972 // (other items were commented in a header).
       
  1973 // -----------------------------------------------------------------------------
       
  1974 //
       
  1975 void CPEEngineInfoImpl::SetEmergencyNumber( const TPEPhoneNumber& aEmergencyNumber )
       
  1976     {
       
  1977     iCallCommandInfo.iEmergencyNumber = aEmergencyNumber;
       
  1978     }
       
  1979 
       
  1980 // -----------------------------------------------------------------------------
       
  1981 // CPEEngineInfoImpl::RemotePartyName
       
  1982 // Remote party's network given name. (CNAP, skype id).
       
  1983 // (other items were commented in a header).
       
  1984 // -----------------------------------------------------------------------------
       
  1985 //
       
  1986 const TPEContactName& CPEEngineInfoImpl::RemotePartyName( 
       
  1987     const TInt aCallId ) const
       
  1988     {
       
  1989     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  1990     return iCurrentCalls[ aCallId ]->RemotePartyName();
       
  1991     }
       
  1992 
       
  1993 // -----------------------------------------------------------------------------
       
  1994 // CPEEngineInfoImpl::ErrorCode
       
  1995 // Error code from basic call info.
       
  1996 // (other items were commented in a header).
       
  1997 // -----------------------------------------------------------------------------
       
  1998 //
       
  1999 TInt CPEEngineInfoImpl::ErrorCode() const
       
  2000     {
       
  2001     return iBasicInfo.iErrorInfo.iErrorCode;
       
  2002     }
       
  2003 
       
  2004 // -----------------------------------------------------------------------------
       
  2005 // CPEEngineInfoImpl::SetNumberOfConferenceMembers
       
  2006 // Sets the number of conference members involved in Conference
       
  2007 // call to the TPECallInfo structure.
       
  2008 // (other items were commented in a header).
       
  2009 // -----------------------------------------------------------------------------
       
  2010 //
       
  2011 void CPEEngineInfoImpl::SetNumberOfConferenceMembers( const TInt aNumberOfMembers, const TInt aCallId )
       
  2012     {
       
  2013     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2014     iCurrentCalls[ aCallId ]->SetNumberOfConferenceMembers( aNumberOfMembers );
       
  2015     }
       
  2016 
       
  2017 // -----------------------------------------------------------------------------
       
  2018 // CPEEngineInfoImpl::ResumeHeldCall
       
  2019 // -----------------------------------------------------------------------------
       
  2020 //
       
  2021 TBool CPEEngineInfoImpl::ResumeHeldCall( const TInt aCallId ) const
       
  2022     {
       
  2023     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2024     return iCurrentCalls[ aCallId ]->ResumeHeldCall(); 
       
  2025     }
       
  2026 
       
  2027 // -----------------------------------------------------------------------------
       
  2028 // From base class MPEDataStore
       
  2029 // -----------------------------------------------------------------------------
       
  2030 //
       
  2031 TInt CPEEngineInfoImpl::CallIndex( TInt aCallId ) const
       
  2032     {
       
  2033     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2034     return iCurrentCalls[ aCallId ]->CallIndex(); 
       
  2035     }
       
  2036 
       
  2037 // -----------------------------------------------------------------------------
       
  2038 // CPEEngineInfoImpl::SetBarringInfo
       
  2039 // Sets Barring information to TPEBasicInfo-structure
       
  2040 // (other items were commented in a header).
       
  2041 // -----------------------------------------------------------------------------
       
  2042 //
       
  2043 void CPEEngineInfoImpl::SetBarringInfo( const TPEBarringInfo& aBarringInfo ) 
       
  2044     {
       
  2045     iBasicInfo.iBarringInfo = aBarringInfo;
       
  2046     }
       
  2047 
       
  2048 // -----------------------------------------------------------------------------
       
  2049 // CPEEngineInfoImpl::SetDeflectInfo
       
  2050 // Sets deflect information to the TPEBasicInfo structure
       
  2051 // (other items were commented in a header).
       
  2052 // -----------------------------------------------------------------------------
       
  2053 //
       
  2054 void CPEEngineInfoImpl::SetDeflectInfo( const TPEActiveForwardInfo& aActiveForward )
       
  2055     {
       
  2056     iBasicInfo.iActiveForward  = aActiveForward;
       
  2057     }
       
  2058 
       
  2059 // -----------------------------------------------------------------------------
       
  2060 // CPEEngineInfoImpl::SetResumeHeldCall
       
  2061 // Set iHeldByUser value to TPECallInfo structure
       
  2062 // -----------------------------------------------------------------------------
       
  2063 //
       
  2064 void CPEEngineInfoImpl::SetResumeHeldCall( const TBool aResumeHeldCall, 
       
  2065     const TInt aCallId )
       
  2066     {
       
  2067     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2068     iCurrentCalls[ aCallId ]->SetResumeHeldCall( aResumeHeldCall ); 
       
  2069     }
       
  2070     
       
  2071 // -----------------------------------------------------------------------------
       
  2072 // CPEEngineInfoImpl::SetSimState
       
  2073 // Sets Sim state to TPEBasicInfo-structure
       
  2074 // (other items were commented in a header).
       
  2075 // -----------------------------------------------------------------------------
       
  2076 //
       
  2077 void CPEEngineInfoImpl::SetSimState( const TPESimState& aSimState )
       
  2078     {
       
  2079     iBasicInfo.iSimState = aSimState;
       
  2080     }
       
  2081 
       
  2082 // -----------------------------------------------------------------------------
       
  2083 // CPEEngineInfoImpl::SetSSCommandInfo
       
  2084 // Sets Suplementary Services command information to TPESSCommandInfo-structure
       
  2085 // (other items were commented in a header).
       
  2086 // -----------------------------------------------------------------------------
       
  2087 //
       
  2088 void CPEEngineInfoImpl::SetSSCommandInfo( const TPESSCommandInfo& aSSCommandInfo ) 
       
  2089     {
       
  2090     iBasicInfo.iSSCommandInfo = aSSCommandInfo; 
       
  2091     }
       
  2092 
       
  2093 // -----------------------------------------------------------------------------
       
  2094 // CPEEngineInfoImpl::SetUserToUserInfo
       
  2095 // Set the user to user info.
       
  2096 // -----------------------------------------------------------------------------
       
  2097 //    
       
  2098 void CPEEngineInfoImpl::SetUserToUserInformation( const TPEUserToUserInfo& aUUI )
       
  2099     {
       
  2100     iCallCommandInfo.iUserToUserInfo = aUUI;
       
  2101     }
       
  2102 
       
  2103 // -----------------------------------------------------------------------------
       
  2104 // CPEEngineInfoImpl::SetUserToUserInfo
       
  2105 // Set the user to user info.
       
  2106 // -----------------------------------------------------------------------------
       
  2107 //   
       
  2108 void CPEEngineInfoImpl::SetRemotePartyName( 
       
  2109     const TPEContactName& aName, 
       
  2110     const TInt aCallId )
       
  2111     {
       
  2112     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2113     iCurrentCalls[ aCallId ]->SetRemotePartyName( aName ); 
       
  2114     }
       
  2115 
       
  2116 // -----------------------------------------------------------------------------
       
  2117 // CPEEngineInfoImpl::CallParameters
       
  2118 // Get the call parameters.
       
  2119 // -----------------------------------------------------------------------------
       
  2120 // 
       
  2121 CCCECallParameters& CPEEngineInfoImpl::CallParameters()
       
  2122     {
       
  2123     return *iCallParams;
       
  2124     }
       
  2125 
       
  2126 // -----------------------------------------------------------------------------
       
  2127 // CPEEngineInfoImpl::SetSwitchToNumberCommand
       
  2128 // Sets switch to number
       
  2129 // -----------------------------------------------------------------------------
       
  2130 //
       
  2131 void CPEEngineInfoImpl::SetSwitchToNumberCommand( 
       
  2132         const TPEPhoneNumber& aPhoneNumber )
       
  2133     {
       
  2134     __ASSERT_DEBUG( !( aPhoneNumber.Length() > KPEPhoneNumberMaxLength ),
       
  2135         Panic( EPEPanicExternalDataIdOutOfRange ) );
       
  2136     iCallCommandInfo.iSwitchToNumber = aPhoneNumber;
       
  2137     }
       
  2138 
       
  2139 // -----------------------------------------------------------------------------
       
  2140 // From base class MPEDataStore
       
  2141 // Sets call index
       
  2142 // -----------------------------------------------------------------------------
       
  2143 //
       
  2144 void CPEEngineInfoImpl::SetCallIndex( TInt aCallIndex, TInt aCallId )
       
  2145     {
       
  2146     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2147     iCurrentCalls[ aCallId ]->SetCallIndex( aCallIndex );
       
  2148     }
       
  2149 
       
  2150 // -----------------------------------------------------------------------------
       
  2151 // From base class MPEDataStore
       
  2152 // Sets call origin
       
  2153 // -----------------------------------------------------------------------------
       
  2154 //
       
  2155 void CPEEngineInfoImpl::SetCallOrigin( TPECallOrigin aOrigin, TInt aCallId )
       
  2156     {
       
  2157     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2158     return iCurrentCalls[ aCallId ]->SetCallOrigin( aOrigin ); 
       
  2159     }
       
  2160 
       
  2161 // -----------------------------------------------------------------------------
       
  2162 // CPEEngineInfoImpl::SwitchToNumberCommand
       
  2163 // Return the switch to number from the TPECallCommandInfo structure.
       
  2164 // -----------------------------------------------------------------------------
       
  2165 //
       
  2166 const TPEPhoneNumber& CPEEngineInfoImpl::SwitchToNumberCommand() const
       
  2167     {
       
  2168     return iCallCommandInfo.iSwitchToNumber;
       
  2169     }
       
  2170 
       
  2171 
       
  2172 // -----------------------------------------------------------------------------
       
  2173 // CPEEngineInfoImpl::UnattendedTransferTarget
       
  2174 // -----------------------------------------------------------------------------
       
  2175 //
       
  2176 const TPEPhoneNumber& CPEEngineInfoImpl::UnattendedTransferTarget( 
       
  2177         TInt aCallId ) const
       
  2178     {
       
  2179     __ASSERT_DEBUG( aCallId < iCurrentCalls.Count(), 
       
  2180         Panic( EPEPanicCallIndexOutOfRange ) );
       
  2181     return iCurrentCalls[ aCallId ]->UnattendedTransferTarget(); 
       
  2182     }
       
  2183 
       
  2184 
       
  2185 // -----------------------------------------------------------------------------
       
  2186 // CPEEngineInfoImpl::SetUnattendedTransferTarget
       
  2187 // -----------------------------------------------------------------------------
       
  2188 //
       
  2189 void CPEEngineInfoImpl::SetUnattendedTransferTarget( const TPEPhoneNumber& aTarget,
       
  2190         TInt aCallId )
       
  2191     {
       
  2192     __ASSERT_DEBUG( aCallId < iCurrentCalls.Count(),
       
  2193         Panic( EPEPanicCallIndexOutOfRange ) );
       
  2194     iCurrentCalls[ aCallId ]->SetUnattendedTransferTarget( aTarget );
       
  2195     }
       
  2196 
       
  2197 // -----------------------------------------------------------------------------
       
  2198 // CPEEngineInfoImpl::ForwardAddressChoices
       
  2199 // -----------------------------------------------------------------------------
       
  2200 //
       
  2201 const CDesC8Array* CPEEngineInfoImpl::ForwardAddressChoices( 
       
  2202         TInt aCallId ) const
       
  2203     {
       
  2204     __ASSERT_DEBUG( aCallId < iCurrentCalls.Count(), 
       
  2205         Panic( EPEPanicCallIndexOutOfRange ) );
       
  2206     return iCurrentCalls[ aCallId ]->ForwardAddressChoices(); 
       
  2207     }
       
  2208 
       
  2209 
       
  2210 // -----------------------------------------------------------------------------
       
  2211 // CPEEngineInfoImpl::SetForwardAddressChoices
       
  2212 // -----------------------------------------------------------------------------
       
  2213 //
       
  2214 void CPEEngineInfoImpl::SetForwardAddressChoices( const CDesC8Array* aArray,
       
  2215         TInt aCallId )
       
  2216     {
       
  2217     __ASSERT_DEBUG( aCallId < iCurrentCalls.Count(),
       
  2218         Panic( EPEPanicCallIndexOutOfRange ) );
       
  2219     iCurrentCalls[ aCallId ]->SetForwardAddressChoices( aArray );
       
  2220     }
       
  2221     
       
  2222 // -----------------------------------------------------------------------------
       
  2223 // CPEEngineInfoImpl::SetForwardAddressIndex
       
  2224 // -----------------------------------------------------------------------------
       
  2225 //
       
  2226 void CPEEngineInfoImpl::SetForwardAddressIndex( TInt aIndex )
       
  2227     {
       
  2228     iCallCommandInfo.iForwardToAddressIndex = aIndex;
       
  2229     }
       
  2230     
       
  2231 // -----------------------------------------------------------------------------
       
  2232 // CPEEngineInfoImpl::ForwardAddressIndex
       
  2233 // -----------------------------------------------------------------------------
       
  2234 //
       
  2235 TInt CPEEngineInfoImpl::ForwardAddressIndex()
       
  2236     {
       
  2237     return iCallCommandInfo.iForwardToAddressIndex;
       
  2238     }
       
  2239 
       
  2240 // -----------------------------------------------------------------------------
       
  2241 // CPEEngineInfoImpl::SetTransferTargetCommand
       
  2242 // (other items were commented in a header).
       
  2243 // -----------------------------------------------------------------------------
       
  2244 //
       
  2245 void CPEEngineInfoImpl::SetTransferTargetCommand( const TPEPhoneNumber& aTransferTarget )
       
  2246     {
       
  2247     iCallCommandInfo.iTransferToAddress = aTransferTarget; 
       
  2248     }
       
  2249 
       
  2250 // -----------------------------------------------------------------------------
       
  2251 // CPEEngineInfoImpl::TransferTarget
       
  2252 // (other items were commented in a header).
       
  2253 // -----------------------------------------------------------------------------
       
  2254 //
       
  2255 const TPEPhoneNumber& CPEEngineInfoImpl::TransferTargetCommand() const
       
  2256     {
       
  2257     return iCallCommandInfo.iTransferToAddress;
       
  2258     }
       
  2259 
       
  2260 // -----------------------------------------------------------------------------
       
  2261 // CPEEngineInfo::SetIsSwitchToOperationOngoing
       
  2262 // (other items were commented in a header).
       
  2263 // -----------------------------------------------------------------------------
       
  2264 //
       
  2265 void CPEEngineInfoImpl::SetIsSwitchToOperationOngoing( const TBool aValue )
       
  2266     {
       
  2267     TEFLOGSTRING2( KTAINT, "SetIsSwitchToOperationOngoing: %d", aValue );
       
  2268     iBasicInfo.iSwitchToOngoing = aValue;
       
  2269     }
       
  2270 
       
  2271 // -----------------------------------------------------------------------------
       
  2272 // CPEEngineInfo::IsSwitchToOperationOngoing
       
  2273 // (other items were commented in a header).
       
  2274 // -----------------------------------------------------------------------------
       
  2275 //
       
  2276 TBool CPEEngineInfoImpl::IsSwitchToOperationOngoing() const
       
  2277     {
       
  2278     TEFLOGSTRING2( KTAINT, "IsSwitchToOperationOngoing: %d", iBasicInfo.iSwitchToOngoing );
       
  2279     return iBasicInfo.iSwitchToOngoing;
       
  2280     }
       
  2281 
       
  2282 // -----------------------------------------------------------------------------
       
  2283 // CPEEngineInfo::CallOrigin
       
  2284 // (other items were commented in a header).
       
  2285 // -----------------------------------------------------------------------------
       
  2286 //
       
  2287 TPECallOrigin CPEEngineInfoImpl::CallOrigin( const TInt aCallId ) const
       
  2288     {
       
  2289     __ASSERT_DEBUG( iCurrentCalls.Count() > aCallId, Panic( EPEPanicCallIndexOutOfRange ) );
       
  2290     return iCurrentCalls[ aCallId ]->CallOrigin();
       
  2291     }
       
  2292 
       
  2293 // -----------------------------------------------------------------------------
       
  2294 // CPEEngineInfoImpl::CallerImage
       
  2295 // -----------------------------------------------------------------------------
       
  2296 //
       
  2297 const TPtrC CPEEngineInfoImpl::CallerImage( const TInt aCallId ) const
       
  2298     {
       
  2299     return ( *iRemoteInfo )[ aCallId ]->CallerImage();
       
  2300     }
       
  2301 
       
  2302 // -----------------------------------------------------------------------------
       
  2303 // CPEEngineInfoImpl::CallerText
       
  2304 // -----------------------------------------------------------------------------
       
  2305 //
       
  2306 const TPtrC CPEEngineInfoImpl::CallerText( const TInt aCallId ) const
       
  2307     {
       
  2308     return ( *iRemoteInfo )[ aCallId ]->CallerText();
       
  2309     }
       
  2310 
       
  2311 // -----------------------------------------------------------------------------
       
  2312 // CPEEngineInfoImpl::CallerThumbnail
       
  2313 // -----------------------------------------------------------------------------
       
  2314 //
       
  2315 CFbsBitmap* CPEEngineInfoImpl::CallerThumbnail( const TInt aCallId ) const
       
  2316     {
       
  2317     return ( *iRemoteInfo )[ aCallId ]->CallerThumbnail();
       
  2318     }
       
  2319 
       
  2320 // -----------------------------------------------------------------------------
       
  2321 // CPEEngineInfoImpl::HasCallerThumbnail
       
  2322 // -----------------------------------------------------------------------------
       
  2323 //
       
  2324 TBool CPEEngineInfoImpl::HasCallerThumbnail( const TInt aCallId ) const
       
  2325    {
       
  2326     return ( *iRemoteInfo )[ aCallId ]->HasCallerThumbnail();
       
  2327     }
       
  2328 
       
  2329 // -----------------------------------------------------------------------------
       
  2330 // CPEEngineInfoImpl::ContactId
       
  2331 // -----------------------------------------------------------------------------
       
  2332 //
       
  2333 const CPhCntContactId& CPEEngineInfoImpl::ContactId( const TInt aCallId ) const
       
  2334     {
       
  2335     return ( *iRemoteInfo )[ aCallId ]->ContactId();
       
  2336     }
       
  2337 
       
  2338 // -----------------------------------------------------------------------------
       
  2339 // CPEEngineInfoImpl::ContactGroups
       
  2340 // -----------------------------------------------------------------------------
       
  2341 //
       
  2342 const TArray< TContactItemId > CPEEngineInfoImpl::ContactGroups(
       
  2343     const TInt aCallId ) const
       
  2344     {
       
  2345     return ( *iRemoteInfo )[ aCallId ]->ContactGroups();
       
  2346     }
       
  2347 
       
  2348 // -----------------------------------------------------------------------------
       
  2349 // CPEEngineInfoImpl::ContactLink
       
  2350 // -----------------------------------------------------------------------------
       
  2351 //
       
  2352 const TDesC8& CPEEngineInfoImpl::ContactLink( const TInt aCallId ) const
       
  2353     {
       
  2354     return ( *iRemoteInfo )[ aCallId ]->ContactLink();
       
  2355     }
       
  2356 
       
  2357 // -----------------------------------------------------------------------------
       
  2358 // CPEEngineInfoImpl::PersonalRingingTone
       
  2359 // -----------------------------------------------------------------------------
       
  2360 //
       
  2361 const TPEContactFileName& CPEEngineInfoImpl::PersonalRingingTone(
       
  2362     const TInt aCallId ) const
       
  2363     {
       
  2364     return ( *iRemoteInfo )[ aCallId ]->PersonalRingingTone();
       
  2365     }
       
  2366 
       
  2367 // -----------------------------------------------------------------------------
       
  2368 // CPEEngineInfoImpl::RemoteCompanyName
       
  2369 // -----------------------------------------------------------------------------
       
  2370 //
       
  2371 const TPEContactCompany& CPEEngineInfoImpl::RemoteCompanyName(
       
  2372     const TInt aCallId ) const
       
  2373     {
       
  2374     return ( *iRemoteInfo )[ aCallId ]->CompanyName();
       
  2375     }
       
  2376 
       
  2377 // -----------------------------------------------------------------------------
       
  2378 // CPEEngineInfoImpl::RemoteName
       
  2379 // -----------------------------------------------------------------------------
       
  2380 //
       
  2381 const TPEContactName& CPEEngineInfoImpl::RemoteName( const TInt aCallId ) const
       
  2382     {
       
  2383     return ( *iRemoteInfo )[ aCallId ]->Name();
       
  2384     }
       
  2385 
       
  2386 // -----------------------------------------------------------------------------
       
  2387 // CPEEngineInfoImpl::RemotePhoneNumber
       
  2388 // -----------------------------------------------------------------------------
       
  2389 //
       
  2390 const TPEPhoneNumber& CPEEngineInfoImpl::RemotePhoneNumber(
       
  2391     const TInt aCallId ) const
       
  2392     {
       
  2393     return ( *iRemoteInfo )[ aCallId ]->PhoneNumber();
       
  2394     }
       
  2395 
       
  2396 // -----------------------------------------------------------------------------
       
  2397 // CPEEngineInfoImpl::RemotePhoneNumberType
       
  2398 // -----------------------------------------------------------------------------
       
  2399 //
       
  2400 const TPEPhoneNumberIdType& CPEEngineInfoImpl::RemotePhoneNumberType(
       
  2401     const TInt aCallId ) const
       
  2402     {
       
  2403     return ( *iRemoteInfo )[ aCallId ]->PhoneNumberType();
       
  2404     }
       
  2405 
       
  2406 // -----------------------------------------------------------------------------
       
  2407 // CPEEngineInfoImpl::RemoteTextToSpeechText
       
  2408 // -----------------------------------------------------------------------------
       
  2409 //
       
  2410 const TPtrC CPEEngineInfoImpl::RemoteTextToSpeechText(
       
  2411     const TInt aCallId ) const
       
  2412     {
       
  2413     return ( *iRemoteInfo )[ aCallId ]->TextToSpeechText();
       
  2414     }
       
  2415 
       
  2416 // -----------------------------------------------------------------------------
       
  2417 // CPEEngineInfoImpl::RemotePredefinedDtmfStrings
       
  2418 // -----------------------------------------------------------------------------
       
  2419 //
       
  2420 const  CDesCArray& CPEEngineInfoImpl::RemotePredefinedDtmfStrings(
       
  2421     const TInt aCallId ) const
       
  2422     {
       
  2423     return ( *iRemoteInfo )[ aCallId ]->PredefinedDtmfStrings();
       
  2424     }
       
  2425 
       
  2426 // -----------------------------------------------------------------------------
       
  2427 // CPEEngineInfoImpl::RemoteColpNumber
       
  2428 // -----------------------------------------------------------------------------
       
  2429 //
       
  2430 const TPEPhoneNumber& CPEEngineInfoImpl::RemoteColpNumber(
       
  2431     const TInt aCallId ) const
       
  2432     {
       
  2433     return ( *iRemoteInfo )[ aCallId ]->ColpNumber();
       
  2434     }
       
  2435 
       
  2436 // -----------------------------------------------------------------------------
       
  2437 // CPEEngineInfoImpl::ResetRemoteInfo
       
  2438 // -----------------------------------------------------------------------------
       
  2439 //
       
  2440 void CPEEngineInfoImpl::ResetRemoteInfo( const TInt aCallId )
       
  2441     {
       
  2442     return ( *iRemoteInfo )[ aCallId ]->ResetRemoteInfo();
       
  2443     }
       
  2444 
       
  2445 // -----------------------------------------------------------------------------
       
  2446 // CPEEngineInfoImpl::SetCallerImage
       
  2447 // -----------------------------------------------------------------------------
       
  2448 //
       
  2449 void CPEEngineInfoImpl::SetCallerImage(
       
  2450     const TPtrC aCallerImage, 
       
  2451     const TInt aCallId )
       
  2452     {
       
  2453     return ( *iRemoteInfo )[ aCallId ]->SetCallerImage( aCallerImage );
       
  2454     }
       
  2455 
       
  2456 // -----------------------------------------------------------------------------
       
  2457 // CPEEngineInfoImpl::SetCallerText
       
  2458 // -----------------------------------------------------------------------------
       
  2459 //
       
  2460 void CPEEngineInfoImpl::SetCallerText(
       
  2461     const TPtrC aCallerText, 
       
  2462     const TInt aCallId )
       
  2463     {
       
  2464     return ( *iRemoteInfo )[ aCallId ]->SetCallerText( aCallerText );
       
  2465     }
       
  2466 
       
  2467 // -----------------------------------------------------------------------------
       
  2468 // CPEEngineInfoImpl::SetCallerThumbnail
       
  2469 // -----------------------------------------------------------------------------
       
  2470 //
       
  2471 void CPEEngineInfoImpl::SetCallerThumbnail(
       
  2472     CFbsBitmap* aCallerThumbnail, 
       
  2473     const TInt aCallId )
       
  2474     {
       
  2475     return ( *iRemoteInfo )[ aCallId ]->SetCallerThumbnail( aCallerThumbnail );
       
  2476     }
       
  2477 
       
  2478 // -----------------------------------------------------------------------------
       
  2479 // CPEEngineInfoImpl::SetHasCallerThumbnail
       
  2480 // -----------------------------------------------------------------------------
       
  2481 //
       
  2482 void CPEEngineInfoImpl::SetHasCallerThumbnail(
       
  2483     TBool aStatus, 
       
  2484     const TInt aCallId )
       
  2485     {
       
  2486     return ( *iRemoteInfo )[ aCallId ]->SetHasCallerThumbnail( aStatus );
       
  2487     }
       
  2488 
       
  2489 // -----------------------------------------------------------------------------
       
  2490 // CPEEngineInfoImpl::SetPredefinedDtmfStrings
       
  2491 // -----------------------------------------------------------------------------
       
  2492 //
       
  2493 void CPEEngineInfoImpl::SetPredefinedDtmfStrings( 
       
  2494     const CDesCArray& aArray, 
       
  2495     const TInt aCallId )            
       
  2496     {
       
  2497     return ( *iRemoteInfo )[ aCallId ]->SetPredefinedDtmfStrings( aArray );
       
  2498     }
       
  2499 
       
  2500 // -----------------------------------------------------------------------------
       
  2501 // CPEEngineInfoImpl::SetContactGroups
       
  2502 // -----------------------------------------------------------------------------
       
  2503 //
       
  2504 void CPEEngineInfoImpl::SetContactGroups(
       
  2505     TArray< TContactItemId >& aGroupIdArray,
       
  2506     const TInt aCallId )
       
  2507     {
       
  2508     return ( *iRemoteInfo )[ aCallId ]->SetContactGroups( aGroupIdArray );
       
  2509     }
       
  2510 
       
  2511 // -----------------------------------------------------------------------------
       
  2512 // CPEEngineInfoImpl::SetContactId
       
  2513 // -----------------------------------------------------------------------------
       
  2514 //
       
  2515 void CPEEngineInfoImpl::SetContactId(
       
  2516         CPhCntContactId* aContactId,
       
  2517         const TInt aCallId )
       
  2518     {
       
  2519     return ( *iRemoteInfo )[ aCallId ]->SetContactId( aContactId );
       
  2520     }
       
  2521 
       
  2522 // -----------------------------------------------------------------------------
       
  2523 // CPEEngineInfoImpl::SetPersonalRingingTone
       
  2524 // -----------------------------------------------------------------------------
       
  2525 //
       
  2526 void CPEEngineInfoImpl::SetPersonalRingingTone(
       
  2527     const TPEContactFileName& aRingingTonepath,
       
  2528     const TInt aCallId )
       
  2529     {
       
  2530     return ( *iRemoteInfo )[ aCallId ]->SetPersonalRingingTone( aRingingTonepath );
       
  2531     }
       
  2532 
       
  2533 // -----------------------------------------------------------------------------
       
  2534 // CPEEngineInfoImpl::SetRemoteCompanyName
       
  2535 // -----------------------------------------------------------------------------
       
  2536 //
       
  2537 void CPEEngineInfoImpl::SetRemoteCompanyName(
       
  2538     const TPEContactName& aCompanyName, 
       
  2539     const TInt aCallId )
       
  2540     {
       
  2541     return ( *iRemoteInfo )[ aCallId ]->SetCompanyName( aCompanyName );
       
  2542     }
       
  2543 
       
  2544 // -----------------------------------------------------------------------------
       
  2545 // CPEEngineInfoImpl::SetRemoteColpNumber
       
  2546 // -----------------------------------------------------------------------------
       
  2547 //
       
  2548 void CPEEngineInfoImpl::SetRemoteColpNumber(
       
  2549     TPEPhoneNumber& aColpNumber, 
       
  2550     const TInt aCallId )
       
  2551     {
       
  2552     return ( *iRemoteInfo )[ aCallId ]->SetColpNumber( aColpNumber );
       
  2553     }
       
  2554 
       
  2555 // -----------------------------------------------------------------------------
       
  2556 // CPEEngineInfoImpl::SetRemoteName
       
  2557 // -----------------------------------------------------------------------------
       
  2558 //
       
  2559 void CPEEngineInfoImpl::SetRemoteName(
       
  2560     const TPEContactName& aContactName, 
       
  2561     const TInt aCallId )
       
  2562     {
       
  2563     return ( *iRemoteInfo )[ aCallId ]->SetName( aContactName );
       
  2564     }
       
  2565 
       
  2566 // -----------------------------------------------------------------------------
       
  2567 // CPEEngineInfoImpl::SetRemotePhoneNumber
       
  2568 // -----------------------------------------------------------------------------
       
  2569 //
       
  2570 void CPEEngineInfoImpl::SetRemotePhoneNumber(
       
  2571     const TPEPhoneNumber& aPhoneNumber, 
       
  2572     const TInt aCallId )
       
  2573     {
       
  2574     return ( *iRemoteInfo )[ aCallId ]->SetPhoneNumber( aPhoneNumber );
       
  2575     }
       
  2576 
       
  2577 // -----------------------------------------------------------------------------
       
  2578 // CPEEngineInfoImpl::SetRemotePhoneNumberType
       
  2579 // -----------------------------------------------------------------------------
       
  2580 //
       
  2581 void CPEEngineInfoImpl::SetRemotePhoneNumberType(
       
  2582     TPEPhoneNumberIdType aPhoneNumberType, 
       
  2583     const TInt aCallId )
       
  2584     {
       
  2585     return ( *iRemoteInfo )[ aCallId ]->SetPhoneNumberType( aPhoneNumberType );
       
  2586     }
       
  2587 
       
  2588 // -----------------------------------------------------------------------------
       
  2589 // CPEEngineInfoImpl::SetRemoteTextToSpeechText
       
  2590 // -----------------------------------------------------------------------------
       
  2591 //
       
  2592 void CPEEngineInfoImpl::SetRemoteTextToSpeechText(
       
  2593     HBufC* aText,
       
  2594     TInt aCallId )
       
  2595     {
       
  2596     return ( *iRemoteInfo )[ aCallId ]->SetTextToSpeechText( aText );
       
  2597     }
       
  2598 
       
  2599 // -----------------------------------------------------------------------------
       
  2600 // CPEEngineInfoImpl::CheckIfCallStateExists
       
  2601 // Checks if given state can be found.
       
  2602 // -----------------------------------------------------------------------------
       
  2603 //
       
  2604 TBool CPEEngineInfoImpl::CheckIfCallStateExists( const TPEState& aCallState )
       
  2605     {
       
  2606     TInt count = iCurrentCalls.Count();
       
  2607     TBool stateExists(EFalse);
       
  2608     for ( TInt i = 0; i < count; i++ )
       
  2609       {
       
  2610       if( aCallState == iCurrentCalls[ i ]->CallState() )
       
  2611           {
       
  2612           stateExists = ETrue;
       
  2613           break;
       
  2614           }
       
  2615       }
       
  2616     return stateExists;
       
  2617     }
       
  2618 
       
  2619 // End of File