phonebookengines/VirtualPhonebook/VPbkSimStoreImpl/src/CSatPhone.cpp
branchRCL_3
changeset 20 f4a778e096c2
parent 0 e686773b3f54
equal deleted inserted replaced
19:5b6f26637ad3 20:f4a778e096c2
       
     1 /*
       
     2 * Copyright (c) 2002-2007 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:  A phone class that supports SAT refresh
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 // INCLUDE FILES
       
    21 #include "csatphone.h"
       
    22 
       
    23 #include "cphone.h"
       
    24 #include "vpbksimstorecommon.h"
       
    25 #include "csatrefreshnotifier.h"
       
    26 #include "vpbksimstoreimplerror.h"
       
    27 
       
    28 namespace VPbkSimStoreImpl {
       
    29 
       
    30 // ============================ MEMBER FUNCTIONS ===============================
       
    31 
       
    32 // -----------------------------------------------------------------------------
       
    33 // CSatPhone::CSatPhone
       
    34 // C++ default constructor can NOT contain any code, that
       
    35 // might leave.
       
    36 // -----------------------------------------------------------------------------
       
    37 //
       
    38 inline CSatPhone::CSatPhone()
       
    39     {
       
    40     }
       
    41 
       
    42 // -----------------------------------------------------------------------------
       
    43 // CSatPhone::ConstructL
       
    44 // Symbian 2nd phase constructor can leave.
       
    45 // -----------------------------------------------------------------------------
       
    46 //
       
    47 inline void CSatPhone::ConstructL()
       
    48     {
       
    49     iSatNotifier = VPbkSimStoreImpl::CSatRefreshNotifier::NewL();
       
    50     iPhone = new( ELeave ) VPbkSimStoreImpl::CPhone(*iSatNotifier);
       
    51     }
       
    52 
       
    53 // -----------------------------------------------------------------------------
       
    54 // CSatPhone::NewL
       
    55 // Two-phased constructor.
       
    56 // -----------------------------------------------------------------------------
       
    57 //
       
    58 CSatPhone* CSatPhone::NewL()
       
    59     {
       
    60     CSatPhone* self = new(ELeave) CSatPhone;
       
    61     CleanupStack::PushL( self );
       
    62     self->ConstructL();
       
    63     CleanupStack::Pop( self );
       
    64     return self;
       
    65     }
       
    66     
       
    67 // Destructor
       
    68 CSatPhone::~CSatPhone()
       
    69     {
       
    70     delete iPhone;
       
    71     delete iSatNotifier;
       
    72     }
       
    73 
       
    74 // -----------------------------------------------------------------------------
       
    75 // CSatPhone::OpenL
       
    76 // -----------------------------------------------------------------------------
       
    77 //  
       
    78 void CSatPhone::OpenL( MVPbkSimPhoneObserver& aObserver )
       
    79     {
       
    80     iPhone->OpenL( aObserver );
       
    81     }
       
    82 
       
    83 // -----------------------------------------------------------------------------
       
    84 // CSatPhone::Close
       
    85 // -----------------------------------------------------------------------------
       
    86 //
       
    87 void CSatPhone::Close( MVPbkSimPhoneObserver& aObserver )
       
    88     {
       
    89     iPhone->Close( aObserver );
       
    90     }
       
    91 
       
    92 // -----------------------------------------------------------------------------
       
    93 // CSatPhone::USimAccessSupported
       
    94 // -----------------------------------------------------------------------------
       
    95 //
       
    96 TBool CSatPhone::USimAccessSupported() const
       
    97     {
       
    98     return iPhone->USimAccessSupported();
       
    99     }
       
   100 
       
   101 // -----------------------------------------------------------------------------
       
   102 // CSatPhone::ServiceTable
       
   103 // -----------------------------------------------------------------------------
       
   104 //
       
   105 TUint32 CSatPhone::ServiceTable() const
       
   106     {
       
   107     return iPhone->ServiceTable();
       
   108     }
       
   109 
       
   110 // -----------------------------------------------------------------------------
       
   111 // CSatPhone::FixedDialingStatus
       
   112 // -----------------------------------------------------------------------------
       
   113 //
       
   114 MVPbkSimPhone::TFDNStatus CSatPhone::FixedDialingStatus() const
       
   115     {
       
   116     return iPhone->FixedDialingStatus();
       
   117     }
       
   118 } // VPbkSimStoreImpl
       
   119 //  End of File