javaextensions/location/position/inc/ctimeouttimer.h
branchRCL_3
changeset 19 04becd199f91
equal deleted inserted replaced
16:f5050f1da672 19:04becd199f91
       
     1 /*
       
     2 * Copyright (c) 2008 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  *
       
    16 */
       
    17 
       
    18 
       
    19 #ifndef CTIMEOUTTIMER_H
       
    20 #define CTIMEOUTTIMER_H
       
    21 
       
    22 //  INCLUDES
       
    23 #include <e32base.h>
       
    24 
       
    25 namespace java
       
    26 {
       
    27 namespace location
       
    28 {
       
    29 // CLASS DECLARATION
       
    30 
       
    31 /**
       
    32  *  Handles timeouts for CTrackingPositioner.
       
    33  */
       
    34 class CTimeoutTimer: public CTimer
       
    35 {
       
    36 public:
       
    37     // Constructors and destructor
       
    38 
       
    39     /**
       
    40      * Two-phased constructor.
       
    41      */
       
    42     static CTimeoutTimer* NewL(const TCallBack& aCallBack);
       
    43 
       
    44     /**
       
    45      * Destructor.
       
    46      */
       
    47     ~CTimeoutTimer();
       
    48 
       
    49 public:
       
    50     // New functions
       
    51 
       
    52     void TimeoutAfter(const TTimeIntervalMicroSeconds& aDelay);
       
    53 
       
    54 protected:
       
    55     // Functions from base classes
       
    56 
       
    57     /**
       
    58      * From CActive
       
    59      */
       
    60     void RunL();
       
    61 
       
    62 private:
       
    63 
       
    64     /**
       
    65      * C++ default constructor.
       
    66      */
       
    67     CTimeoutTimer(const TCallBack& aCallBack);
       
    68 
       
    69     // Prohibit copy constructor if not deriving from CBase.
       
    70     // ?classname( const ?classname& );
       
    71     // Prohibit assigment operator if not deriving from CBase.
       
    72     // ?classname& operator=( const ?classname& );
       
    73 
       
    74 private:
       
    75     // Data
       
    76     TTime iTimeoutTime;
       
    77     TCallBack iCallBack;
       
    78 };
       
    79 
       
    80 }
       
    81 }
       
    82 
       
    83 #endif // CTIMEOUTTIMER_H
       
    84 // End of File