messagingapp/msgnotifications/msgerrorwatcher/inc/msgerrorroamingobserver.h
changeset 70 a15d9966050f
equal deleted inserted replaced
61:8ba0afbb4637 70:a15d9966050f
       
     1 /*
       
     2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  
       
    15 *     CMsgErrorRoamingObserver declaration file
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 
       
    21 #ifndef MSGERRORROAMINGOBSERVER_H
       
    22 #define MSGERRORROAMINGOBSERVER_H
       
    23 
       
    24 //  INCLUDES
       
    25 #include <e32base.h>
       
    26 #include <etel.h>                   //RTelServer
       
    27 #include <etelmm.h>
       
    28 
       
    29 
       
    30 
       
    31 // FORWARD DECLARATIONS
       
    32 class CMsgErrorWatcherPrivate;
       
    33 
       
    34 // CLASS DECLARATION
       
    35 
       
    36 /**
       
    37 * CMsgErrorRoamingObserver
       
    38 */
       
    39 class CMsgErrorRoamingObserver : public CActive
       
    40     {
       
    41     public:  // Constructors and destructor
       
    42         
       
    43         /**
       
    44         * Two-phased constructor.
       
    45         *
       
    46         * @param aWatcher A pointer to CMsgErrorWatcherPrivate
       
    47         */
       
    48         static CMsgErrorRoamingObserver* NewL( CMsgErrorWatcherPrivate& aWatcher );
       
    49         
       
    50         /**
       
    51         * Destructor.
       
    52         */
       
    53         virtual ~CMsgErrorRoamingObserver();
       
    54 
       
    55     private:
       
    56 
       
    57         /**
       
    58         * Checks whether roaming status has changed
       
    59         * from home network to roaming or vice versa.
       
    60         * If so, calls CMsgErrorWatcherPrivate::HandleRoamingEventL
       
    61         */
       
    62         void UpdateRoamingStatusL();
       
    63 
       
    64         /**
       
    65         * By default Symbian OS constructor is private.
       
    66         */
       
    67         void ConstructL();
       
    68 
       
    69         /**
       
    70         * Private C++ constructor.
       
    71         *
       
    72         * @param aWatcher A pointer to CMsgErrorWatcherPrivate
       
    73         */
       
    74         CMsgErrorRoamingObserver( CMsgErrorWatcherPrivate& aWatcher );
       
    75 
       
    76     private:
       
    77 
       
    78         /**
       
    79         * For starting the active object.
       
    80         */
       
    81         void Start();
       
    82 
       
    83         /**
       
    84         * From CActive
       
    85         */
       
    86         void DoCancel();
       
    87 
       
    88         /**
       
    89         * From CActive
       
    90         */
       
    91         void RunL();
       
    92 
       
    93     private:    // Data
       
    94 
       
    95         CMsgErrorWatcherPrivate&   iWatcher;
       
    96         TBool               iRoaming;
       
    97         RMobilePhone        iMobilePhone;
       
    98         RTelServer          iETelServer;
       
    99         RMobilePhone::TMobilePhoneRegistrationStatus iRegStatus;
       
   100         TInt                iRequestId;
       
   101 
       
   102     };
       
   103 
       
   104 #endif      // MSGERRORROAMINGOBSERVER_H
       
   105             
       
   106 // End of File