os/persistentdata/loggingservices/eventlogger/LogServ/src/LogServShutDownTimer.cpp
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 //
    15 
    16 #include "LogServShutdownTimer.h"
    17 
    18 
    19 /////////////////////////////////////////////////////////////////////////////////////////
    20 // -----> CLogServShutdownTimer (source)
    21 /////////////////////////////////////////////////////////////////////////////////////////
    22 
    23 CLogServShutdownTimer::CLogServShutdownTimer(TInt aPriority)
    24 :	CTimer(aPriority)
    25 	{
    26 	CActiveScheduler::Add(this);
    27 	}
    28 
    29 void CLogServShutdownTimer::ConstructL()
    30 	{
    31 	CTimer::ConstructL();
    32 	}
    33 
    34 CLogServShutdownTimer* CLogServShutdownTimer::NewL(TInt aPriority)
    35 	{
    36 	CLogServShutdownTimer* self = new(ELeave) CLogServShutdownTimer(aPriority);
    37 	CleanupStack::PushL(self);
    38 	self->ConstructL();
    39 	CleanupStack::Pop(self);
    40 	return self;
    41 	}
    42 
    43 /////////////////////////////////////////////////////////////////////////////////////////
    44 /////////////////////////////////////////////////////////////////////////////////////////
    45 /////////////////////////////////////////////////////////////////////////////////////////
    46 
    47 void CLogServShutdownTimer::Start()
    48 	{
    49 	After(KLogShutdownDelay);
    50 	}
    51 
    52 /////////////////////////////////////////////////////////////////////////////////////////
    53 /////////////////////////////////////////////////////////////////////////////////////////
    54 /////////////////////////////////////////////////////////////////////////////////////////
    55 
    56 void CLogServShutdownTimer::RunL()
    57 	{
    58 	// Initiate server exit when the timer expires
    59 	CActiveScheduler::Stop();
    60 	}