videofeeds/utils/inc/CIptvTimer.h
branchRCL_3
changeset 23 befca0ec475f
parent 0 96612d01cf9f
equal deleted inserted replaced
22:839377eedc2b 23:befca0ec475f
       
     1 /*
       
     2 * Copyright (c) 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 the License "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:    Timer*
       
    15 */
       
    16 
       
    17 
       
    18 
       
    19 
       
    20 #ifndef __CIPTVTIMER_H__
       
    21 #define __CIPTVTIMER_H__
       
    22 
       
    23 // INCLUDES
       
    24 #include <e32base.h>
       
    25 
       
    26 // FORWARD DECLARATIONS
       
    27 class MIptvTimerObserver;
       
    28 
       
    29 // CLASS DECLARATION
       
    30 /**
       
    31 * This class will notify an object after a specified timeout.
       
    32 * @lib IptvUtil.lib
       
    33 */
       
    34 class CIptvTimer : public CTimer
       
    35     {
       
    36     public: // Constructors and destructors
       
    37 
       
    38         /**
       
    39         * Two-phased constructor.
       
    40         * Creates a CIptvTimer object using two phase construction,
       
    41         * and returns a pointer to the created object.
       
    42         *
       
    43         * @param aPriority      Priority to use for this timer.
       
    44         * @param aTimerObserver Object to notify of timeout event.
       
    45         * @return               A pointer to the created instance of CIptvTimer.
       
    46         */
       
    47         IMPORT_C static CIptvTimer* NewL( const TInt aPriority,
       
    48             MIptvTimerObserver& aTimerObserver );
       
    49 
       
    50         /**
       
    51         * Two-phased constructor.
       
    52         * Creates a CIptvTimer object using two phase construction,
       
    53         * and returns a pointer to the created object.
       
    54         *
       
    55         * @param aPriority      Priority to use for this timer.
       
    56         * @param aTimerObserver Object to notify of timeout event.
       
    57         * @return               A pointer to the created instance of CIptvTimer.
       
    58         */
       
    59         IMPORT_C static CIptvTimer* NewLC( const TInt aPriority,
       
    60             MIptvTimerObserver& aTimerObserver );
       
    61 
       
    62         /**
       
    63         * Destructor.
       
    64         * Destroys the object and releases all memory objects.
       
    65         */
       
    66         virtual IMPORT_C ~CIptvTimer();
       
    67 
       
    68     protected: // Functions from base classes
       
    69 
       
    70         /**
       
    71         * From CActive, RunL.
       
    72         * Called when operation completes.
       
    73         */
       
    74         IMPORT_C void RunL();
       
    75 
       
    76     private: // Constructors and destructors
       
    77 
       
    78         /**
       
    79         * C++ default constructor.
       
    80         * Performs the first phase of two phase construction.
       
    81         *
       
    82         * @param aPriority      Priority to use for this timer.
       
    83         * @param aTimeOutNotify An observer to notify.
       
    84         */
       
    85         IMPORT_C CIptvTimer( const TInt aPriority,
       
    86             MIptvTimerObserver& aTimerObserver );
       
    87 
       
    88         /**
       
    89         * ConstructL.
       
    90         * 2nd phase constructor.
       
    91         */
       
    92         IMPORT_C void ConstructL();
       
    93 
       
    94     private: // Data
       
    95 
       
    96         /**
       
    97         * iNotify, the observer for this objects events.
       
    98         */
       
    99         MIptvTimerObserver& iObserver;
       
   100     };
       
   101 
       
   102 #endif // __CIPTVTIMER_H__
       
   103 
       
   104 // End of File