39
|
1 |
/*
|
|
2 |
* ==============================================================================
|
|
3 |
* Name : epos_csuplsessionretryq.h
|
|
4 |
* Part of : SUPL Framework / SUPL Server
|
|
5 |
* Interface : --
|
|
6 |
* Description : Class to handle retries of failed requests. It waits for all the current sessions to end and then
|
|
7 |
* notifies the failed sessions that they can retry.
|
|
8 |
* Version :
|
|
9 |
*
|
|
10 |
* Copyright (c) 2010 Nokia Corporation.
|
|
11 |
* This material, including documentation and any related
|
|
12 |
* computer programs, is protected by copyright controlled by
|
|
13 |
* Nokia Corporation. All rights are reserved. Copying,
|
|
14 |
* including reproducing, storing, adapting or translating, any
|
|
15 |
* or all of this material requires the prior written consent of
|
|
16 |
* Nokia Corporation. This material also contains confidential
|
|
17 |
* information which may not be disclosed to others without the
|
|
18 |
* prior written consent of Nokia Corporation.
|
|
19 |
* ==============================================================================
|
|
20 |
*/
|
|
21 |
|
|
22 |
#ifndef EPOS_CSUPLSESSIONRETRYQ_H
|
|
23 |
#define EPOS_CSUPLSESSIONRETRYQ_H
|
|
24 |
|
|
25 |
// INCLUDES
|
|
26 |
#include <e32base.h>
|
|
27 |
|
|
28 |
// CLASS DECLARATION
|
|
29 |
class CSuplSessionRequest;
|
|
30 |
|
|
31 |
/**
|
|
32 |
* Class to handle retries of failed requests. It waits for all the current sessions to end and then
|
|
33 |
* notifies the failed sessions that they can retry.
|
|
34 |
*/
|
|
35 |
class CSuplSessionRetryQ : public CTimer
|
|
36 |
{
|
|
37 |
public:
|
|
38 |
static CSuplSessionRetryQ* NewL();
|
|
39 |
~CSuplSessionRetryQ();
|
|
40 |
|
|
41 |
void AddToQueueL(CSuplSessionRequest& aSessionRequest);
|
|
42 |
void RemoveFromQueueL(CSuplSessionRequest& aSessionRequest);
|
|
43 |
void SessionStarted();
|
|
44 |
void SessionEnded();
|
|
45 |
|
|
46 |
private:
|
|
47 |
CSuplSessionRetryQ();
|
|
48 |
void ConstructL();
|
|
49 |
|
|
50 |
// By default, prohibit copy constructor
|
|
51 |
CSuplSessionRetryQ( const CSuplSessionRetryQ& );
|
|
52 |
// Prohibit assigment operator
|
|
53 |
CSuplSessionRetryQ& operator= ( const CSuplSessionRetryQ& );
|
|
54 |
|
|
55 |
protected: // Functions from base classes
|
|
56 |
|
|
57 |
/**
|
|
58 |
* From CActive.
|
|
59 |
* Called when timer completes
|
|
60 |
*/
|
|
61 |
void RunL();
|
|
62 |
|
|
63 |
private: // Data
|
|
64 |
RPointerArray<CSuplSessionRequest> iSessionRequests;
|
|
65 |
TInt iSessionCount;
|
|
66 |
TBool iSomeSessionEnded;
|
|
67 |
TTime iTimeOfLastEndedSession;
|
|
68 |
};
|
|
69 |
|
|
70 |
#endif // EPOS_CSUPLSESSIONRETRYQ_H
|
|
71 |
|
|
72 |
// End of File
|