vtengines/videoteleng/CallCtrl/Inc/CVtCtlLineMonitor.h
changeset 0 ed9695c8bcbe
equal deleted inserted replaced
-1:000000000000 0:ed9695c8bcbe
       
     1 /*
       
     2 * Copyright (c) 2004 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:  Monitors new calls on data line.
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef CVTCTLLINEMONITOR_H
       
    21 #define CVTCTLLINEMONITOR_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include <e32base.h>
       
    25 #include <etelmm.h>
       
    26 
       
    27 // FORWARD DECLARATIONS
       
    28 
       
    29 class MVtCtlLineEventObserver;
       
    30 
       
    31 // CLASS DECLARATION
       
    32 
       
    33 /**
       
    34 *  Monitor for new calls
       
    35 *
       
    36 *  @lib CSCallCtrl
       
    37 *  @since 2.6
       
    38 */
       
    39 NONSHARABLE_CLASS( CVtCtlLineMonitor ) : public CActive
       
    40     {
       
    41     public:  // Constructors and destructor
       
    42         
       
    43         /**
       
    44         * C++ constructor.
       
    45         * @param aLine line subsession
       
    46         * @param aObserver line event observer
       
    47         */
       
    48         /*****************************************************
       
    49         *   Series 60 Customer / ETel
       
    50         *   Series 60  ETel API
       
    51         *****************************************************/
       
    52         CVtCtlLineMonitor( 
       
    53             RMobileLine& aLine,
       
    54             MVtCtlLineEventObserver& aObserver);
       
    55 
       
    56         /**
       
    57         * Destructor.
       
    58         */
       
    59         virtual ~CVtCtlLineMonitor();
       
    60 
       
    61     public: // New functions
       
    62         
       
    63         /**
       
    64         * Starts monitoring
       
    65         */
       
    66         void Start();
       
    67 
       
    68     private:  // Functions from CActive
       
    69 
       
    70         /**
       
    71         * Cancel monitoring.
       
    72         */
       
    73         virtual void DoCancel();
       
    74 
       
    75         /**
       
    76         * Handles new call on line.
       
    77         */
       
    78         virtual void RunL();
       
    79                 
       
    80         /**
       
    81         * Error handler for leave in RunL
       
    82         * @param aError error code
       
    83         * @return KErrNone
       
    84         */
       
    85         virtual TInt RunError( TInt aError );
       
    86 
       
    87     private:    // Data
       
    88 
       
    89         // Data line
       
    90         /*****************************************************
       
    91         *   Series 60 Customer / ETel
       
    92         *   Series 60  ETel API
       
    93         *****************************************************/
       
    94         RMobileLine& iLine;
       
    95         
       
    96         // Observer for new calls on line
       
    97         MVtCtlLineEventObserver& iObserver;
       
    98 
       
    99         // Call name
       
   100         TName        iName;
       
   101 
       
   102         /*****************************************************
       
   103         *   Series 60 Customer / ETel
       
   104         *   Series 60  ETel API
       
   105         *****************************************************/
       
   106         RMobileCall::TMobileCallStatus iLastLineStatus;
       
   107         RMobileCall::TMobileCallStatus iLineStatus;
       
   108     };
       
   109 
       
   110 #endif      // CVTCTLLINEMONITOR_H   
       
   111 
       
   112 // End of File