Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
platform
Web
WebRequestHandlePool.h
1
// Copyright eeGeo Ltd (2012-2015), All Rights Reserved
2
#pragma once
3
4
#include "Types.h"
5
#include "Web.h"
6
7
#include <string>
8
#include <vector>
9
#include <queue>
10
11
namespace
Eegeo
12
{
13
namespace
Web
14
{
15
class
WebRequestHandlePool
:
private
Eegeo::NonCopyable
16
{
17
public
:
18
WebRequestHandlePool
(
const
int
poolSize,
const
std::string& caCertFilePath);
19
~
WebRequestHandlePool
();
20
21
bool
HasCapacity()
const
;
22
23
bool
TryGetHandle(
WebRequestHandle
*& pOutHandle);
24
void
ReturnHandle(
WebRequestHandle
* pHandle);
25
26
const
std::vector<WebRequestHandle*>& GetHandlesInUse()
const
;
27
private
:
28
std::vector<WebRequestHandle*> m_handlesInUse;
29
std::queue<WebRequestHandle*> m_handlesFree;
30
std::vector<WebRequestHandle*> m_handles;
// debugging aid -- use to track handle in order of allocation (so we can say "slot 1 completed request, etc.")
31
};
32
}
33
}
Generated on Sat Jun 10 2023 02:00:35 for eeGeo Platform SDK by
1.8.3.1