WebServerPage.h
上传用户:dengkfang
上传日期:2008-12-30
资源大小:5233k
文件大小:2k
源码类别:

CA认证

开发平台:

Visual C++

  1. #if !defined(AFX_WEBSERVERPAGE_H__7CB72461_171C_4269_B3C8_C0824E6BD5AC__INCLUDED_)
  2. #define AFX_WEBSERVERPAGE_H__7CB72461_171C_4269_B3C8_C0824E6BD5AC__INCLUDED_
  3. #if _MSC_VER > 1000
  4. #pragma once
  5. #endif // _MSC_VER > 1000
  6. // WebServerPage.h : header file
  7. //
  8. #include ".W3MfcW3Mfc.h"
  9. #include ".W3MfcHttpClient.h"
  10. #include ".ControlStaticTreeStaticTreeCtrl.h"
  11. /////////////////////////////////////////////////////////////////////////////
  12. // CWebServerPage dialog
  13. class CMiniCaHttpServer : public CHttpServer
  14. {
  15. public:
  16. void OnError(const CString& sError);
  17. };
  18. class CMiniCAHttpClient : public CHttpClient
  19. {
  20. // friend class CWebServerPage;
  21. public:
  22.   virtual void PostLog(int nHTTPStatusCode, DWORD dwBodyLength);
  23.   DECLARE_DYNCREATE(CMiniCAHttpClient)
  24. };
  25. class CWebServerPage : public CPropertyPage
  26. {
  27. DECLARE_DYNCREATE(CWebServerPage)
  28. // Construction
  29. public:
  30. static void AddMsg(CString strMsg, BOOL bClient = TRUE, 
  31. BOOL bSucceed = TRUE); //默认正确消息,并向客户端添加
  32. void TranslateCT();
  33. BOOL IsWebRun();
  34. void StopServer();
  35. BOOL Service();
  36. CMiniCaHttpServer* pTheWebServer;
  37. static CStaticTreeCtrl * m_pWebTree;
  38. HTREENODE m_hWebRoot;
  39. static HTREENODE m_hWebServer;
  40. static HTREENODE m_hWebClient;
  41. CWebServerPage();
  42. ~CWebServerPage();
  43. //Methods
  44. #ifdef W3MFC_SSL_SUPPORT
  45.   static CCriticalSection* m_pOpenSSLCritSections;
  46.   static void __cdecl OpenSSLLockingCallback(int mode, int type, const char* file, int line);
  47. #endif
  48. // Dialog Data
  49. //{{AFX_DATA(CWebServerPage)
  50. enum { IDD = IDD_PROPPAGE_WEBSERVER };
  51. CStaticTreeCtrl m_WebTree;
  52. //}}AFX_DATA
  53. // Overrides
  54. // ClassWizard generate virtual function overrides
  55. //{{AFX_VIRTUAL(CWebServerPage)
  56. protected:
  57. virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
  58. //}}AFX_VIRTUAL
  59. // Implementation
  60. protected:
  61. // Generated message map functions
  62. //{{AFX_MSG(CWebServerPage)
  63. afx_msg void OnServer();
  64. virtual BOOL OnInitDialog();
  65. afx_msg void OnBstop();
  66. afx_msg void OnClose();
  67. afx_msg void OnDestroy();
  68. afx_msg void OnBresert();
  69. afx_msg void OnBclear();
  70. //}}AFX_MSG
  71. DECLARE_MESSAGE_MAP()
  72. };
  73. //{{AFX_INSERT_LOCATION}}
  74. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  75. #endif // !defined(AFX_WEBSERVERPAGE_H__7CB72461_171C_4269_B3C8_C0824E6BD5AC__INCLUDED_)