tzservices/tzserver/Client/Include/tzchangenotifier.h
author Peter Fordham <peter.fordham@gmail.com>
Fri, 19 Mar 2010 13:24:56 -0700
branchCompilerCompatibility
changeset 10 b19595f53fff
parent 0 2e3d3ce01487
permissions -rw-r--r--
Bug 1790 - Remove static from definition of usage functions.

// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
// All rights reserved.
// This component and the accompanying materials are made available
// under the terms of "Eclipse Public License v1.0"
// which accompanies this distribution, and is available
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
//
// Initial Contributors:
// Nokia Corporation - initial contribution.
//
// Contributors:
//
// Description:
//

#ifndef __tzchangenotifier_h__
#define __tzchangenotifier_h__

#include <e32base.h>

class RTz;
class CTzConverter;
class CTzRuleHolder;

//-------------------------------------------------------------------------
/**
Observes the Time Zone Server and relays change notification of time zone
to the rules holder so it can clear its cache.

@internalComponent
@since 9.1
*/
class CTzChangeNotifier : public CActive
	{
public:
	~CTzChangeNotifier();
	static CTzChangeNotifier* NewL( CTzRuleHolder& aRulesHolder );
	TInt StartObserving();
	void StopObserving();
	
	void RunIfReadyL();

private:
    inline CTzChangeNotifier( CTzRuleHolder& aRulesHolder );

	// from CActive
	virtual void RunL();
	virtual void DoCancel();

private:
    CTzRuleHolder& iRulesHolder;
	};

inline CTzChangeNotifier::CTzChangeNotifier( CTzRuleHolder& aRulesHolder ) :
		CActive       (CActive::EPriorityStandard), 
		iRulesHolder  (aRulesHolder)
		{
		}

#endif