-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathOrchestrator.h
34 lines (25 loc) · 930 Bytes
/
Orchestrator.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#pragma once
#include <map>
#include <list>
#include "ThreadWorker.h"
class SettingsStorage;
class CHttpHeaders;
class ITransactionProcessor;
class COrchestrator :
public CThreadWorker
{
CRITICAL_SECTION m_cs;
SettingsStorage& m_settings;
std::map<DWORD, CString> m_incompleteRequests;
std::map<DWORD, CString> m_incompleteResponses;
std::list<ITransactionProcessor*> m_transactionProcessors;
bool CheckIntegrity(DWORD context, CHttpHeaders& headers, CString& text, std::map<DWORD, CString>& incompletes);
public:
COrchestrator(void);
~COrchestrator(void);
void OnRequest(DWORD context, LPCTSTR text, DWORD length, bool isSSL);
void OnResponse(DWORD context, LPCTSTR text, DWORD length, bool isSSL);
void AddProcessor(ITransactionProcessor* processor);
void RemoveProcessor(ITransactionProcessor* processor);
virtual void OnRunBackground(DWORD dwContext);
};