networkcontrol/ipnetworklayer/inc/idletimer.h
changeset 0 af10295192d8
equal deleted inserted replaced
-1:000000000000 0:af10295192d8
       
     1 /**
       
     2 * Copyright (c) 2005-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:
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef IDLETIMERS_H_
       
    21 #define IDLETIMERS_H_
       
    22 
       
    23 #include <e32base.h>
       
    24 #include <comms-infras/metadata.h>
       
    25 
       
    26 static const TInt KTimerTick = 1000000;
       
    27 static const TInt KTimerCorrectionPeriod = 4;
       
    28 /**
       
    29  *Don't ever want to set a timer for much less than 1/5 of a second
       
    30  */
       
    31 static const TInt KMinTimerTick = KTimerTick / 5;
       
    32 
       
    33 enum 
       
    34     {
       
    35     EPacketActivity,
       
    36     EIdleTimerValues
       
    37     };
       
    38 
       
    39 class TPacketActivity : public Meta::SMetaData
       
    40     {
       
    41 public:    
       
    42     enum 
       
    43         { 
       
    44         iId = EPacketActivity,
       
    45         iUid = 0x10281DFD //same as the IdleTimers.dll
       
    46         };
       
    47 
       
    48     TPacketActivity(TBool* aPacketActivity)
       
    49     	:iPacketActivity(aPacketActivity) {}
       
    50 
       
    51 	volatile TBool* iPacketActivity;
       
    52     DATA_VTABLE
       
    53     };
       
    54     
       
    55 
       
    56 class TIdleTimerValues : public Meta::SMetaData
       
    57     {
       
    58 public:    
       
    59     enum 
       
    60         { 
       
    61         iId = EIdleTimerValues,
       
    62         iUid = 0x10281DFD //same as the IdleTimers.dll
       
    63         };
       
    64 
       
    65     TUint32 iShortTimer;
       
    66     TUint32 iMediumTimer;
       
    67     TUint32 iLongTimer;
       
    68     
       
    69     DATA_VTABLE
       
    70     };
       
    71 	
       
    72 
       
    73 #endif //IDLETIMERS_H_