examples/SDKExamples/ClientServerAsync/client/inc/csasyncrequesthandler.h

00001 /*
00002 * ==============================================================================
00003 *  Name        : csasyncrequesthandler.h
00004 *  Part of     : CSAsync
00005 *  Interface   :
00006 *  Description :
00007 *  Version     :
00008 *
00009 *  Copyright (c) 2004-2006 Nokia Corporation and/or its subsidiary(-ies).
00010 *  All rights reserved.
00011 *  This component and the accompanying materials are made available
00012 *  under the terms of "Eclipse Public License v1.0"
00013 *  which accompanies this distribution, and is available
00014 *  at the URL "http://www.eclipse.org/legal/epl-v10.html".
00015 * ==============================================================================
00016 */
00017 
00018 
00019 #ifndef __CCSASYNCREQUESTHANDLER_H__
00020 #define __CCSASYNCREQUESTHANDLER_H__
00021 
00022 // INCLUDE FILES
00023 #include <e32base.h>
00024 #include "TimeServerSession.h"
00025 
00026 // FORWARD DECLARATIONS
00027 class MAsyncTimeObserver;
00028 
00029 // CLASS DECLARATION
00035 class CCSAsyncRequestHandler : public CActive
00036     {
00037     public: // Constructors and destructors
00047         static CCSAsyncRequestHandler* NewL( MAsyncTimeObserver& aObserver );
00048 
00058         static CCSAsyncRequestHandler* NewLC( MAsyncTimeObserver& aObserver );
00059 
00065         virtual ~CCSAsyncRequestHandler();
00066 
00067     public: // New functions
00068 
00073         void RequestTime();
00074 
00079         void CancelRequest() ;
00080 
00086         TTime Time() const;
00087 
00088     protected: // Functions from base classes
00089 
00095         void RunL();
00096 
00101         void DoCancel();
00102 
00103     private: // Constructors and destructors
00104 
00111         CCSAsyncRequestHandler( MAsyncTimeObserver& aObserver );
00112 
00118         void ConstructL();
00119 
00120     private: // Data
00121 
00125         RTimeServerSession iSession;
00126 
00130         TTime iTime;
00131 
00135         MAsyncTimeObserver& iObserver;
00136     };
00137 
00138 
00139 #endif //__CCSASYNCREQUESTHANDLER_H__
00140 
00141 // End of File

Generated by  doxygen 1.6.2