mmserv/tms/tmscallserver/inc/cspeteldtmfstopmonitor.h
changeset 12 5a06f39ad45b
equal deleted inserted replaced
0:71ca22bcf22a 12:5a06f39ad45b
       
     1 /*
       
     2  * Copyright (c) 2009 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: Telephony Multimedia Service
       
    15  *
       
    16  */
       
    17 
       
    18 #ifndef CSPETELDTMFSTOPMONITOR_H
       
    19 #define CSPETELDTMFSTOPMONITOR_H
       
    20 
       
    21 #include <e32base.h>
       
    22 #include <etelmm.h>
       
    23 
       
    24 namespace TMS {
       
    25 
       
    26 // FORWARD DECLARATIONS
       
    27 class TMSDTMFProvider;
       
    28 
       
    29 /**
       
    30  * TMSEtelDtmfStopMonitor class
       
    31  *
       
    32  * Monitors single ETel RMobilePhone for DTMF events.
       
    33  *
       
    34  * This monitor is applied only for listening incoming calls, i.e.
       
    35  * line capabilites are not monitored.
       
    36  *
       
    37  * @lib csplugin.dll
       
    38  *
       
    39  */
       
    40 class TMSEtelDtmfStopMonitor : public CActive
       
    41     {
       
    42 public:
       
    43     /**
       
    44      * Two-phased constructing for the monitor.
       
    45      *
       
    46      * @param aObserver the observer for getting notification
       
    47      * @param aPhone the line to monitor
       
    48      */
       
    49     static TMSEtelDtmfStopMonitor* NewL(TMSDTMFProvider& aObserver,
       
    50             RMobilePhone& aPhone);
       
    51 
       
    52     /**
       
    53      * C++ default destructor
       
    54      */
       
    55     virtual ~TMSEtelDtmfStopMonitor();
       
    56 
       
    57     /**
       
    58      * Start monitoring call events
       
    59      */
       
    60     void StartMonitoring();
       
    61 
       
    62 protected: // From CActive
       
    63     /**
       
    64      * From CActive
       
    65      * RunL
       
    66      */
       
    67     void RunL();
       
    68 
       
    69     /**
       
    70      * From CActive
       
    71      * Cancels the monitor
       
    72      */
       
    73     void DoCancel();
       
    74 
       
    75 private:
       
    76     /**
       
    77      * C++ default constructor
       
    78      * @param aObserver the observer for status change (incoming call)
       
    79      * @param aPhone the line associated with the call
       
    80      */
       
    81     TMSEtelDtmfStopMonitor(TMSDTMFProvider& aObserver, RMobilePhone& aPhone);
       
    82 
       
    83 private:
       
    84     /**
       
    85      * Forwards events.
       
    86      */
       
    87     TMSDTMFProvider& iObserver;
       
    88 
       
    89     /**
       
    90      * Phone that is being observed for incoming call.
       
    91      */
       
    92     RMobilePhone& iPhone;
       
    93 
       
    94     /**
       
    95      * Event received.
       
    96      */
       
    97     RMobilePhone::TMobilePhoneDTMFEvent iEventData;
       
    98 
       
    99     };
       
   100 
       
   101 } //namespace TMS
       
   102 
       
   103 #endif // CSPETELDTMFSTOPMONITOR_H
       
   104