Changeset 28 in cheroxy for trunk/include/CRXProxy.h
- Timestamp:
- 11/16/12 13:07:05 (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/CRXProxy.h
r24 r28 10 10 #include "CRXHttpRequest.h" 11 11 #include "CRXHttpResponse.h" 12 #include "CRXFilter.h" 12 13 13 14 #define ERROR_PROXY -10000 … … 17 18 #define ERROR_PROXY_FAILED_TO_SEND_RESPONSE ERROR_PROXY - 4 18 19 #define ERROR_PROXY_FAILED_TO_CONNECT_TO_SERVER ERROR_PROXY - 5 19 #define ERROR_PROXY_FAILED_TO_SET_RESPONSE ERROR_PROXY - 520 #define ERROR_PROXY_FAILED_TO_SET_RESPONSE ERROR_PROXY - 6 20 21 21 typedef enum {22 CRX_PROXY_STATUS_ERROR = -1,23 CRX_PROXY_STATUS_IDLE,24 CRX_PROXY_STATUS_BUSY25 } E_CRX_PROXY_STATUS;26 22 27 23 class CRXProxy : public CRXException 28 24 { 29 25 private: 26 bool mIsIntercepted; 27 30 28 CRXSocket mClient; 31 29 CRXSocket mServer; … … 34 32 CRXHttpResponse mHttpResponse; 35 33 36 E_CRX_PROXY_STATUS mProxyStatus;34 static CRXFilter mFilter; 37 35 38 36 public: … … 43 41 44 42 public: 43 /* common utilities */ 45 44 void ReleaseInstance (void); 46 45 … … 48 47 void Close (void); 49 48 50 int GetStatus (void); 49 public: 50 /* interface to filter */ 51 void SetRequestFilter (const E_CRX_FILTER_REQUEST aType, 52 const bool aIsMatched, 53 const std::string aValue); 54 void RemoveRequestFilter (const E_CRX_FILTER_REQUEST aType); 55 bool CheckRequestFilter (const E_CRX_FILTER_REQUEST aType); 51 56 52 57 public: 58 /* for communication */ 53 59 int Forward (void); 54 60
Note:
See TracChangeset
for help on using the changeset viewer.