FirewallAppView.h
上传用户:wlquartz
上传日期:2022-03-04
资源大小:89k
文件大小:2k
开发平台:

Visual C++

  1. // FirewallAppView.h : interface of the CFirewallAppView class
  2. //
  3. /////////////////////////////////////////////////////////////////////////////
  4. #if !defined(AFX_FIREWALLAPPVIEW_H__A4ED256D_C173_47E8_8DA9_9C8C20CB2073__INCLUDED_)
  5. #define AFX_FIREWALLAPPVIEW_H__A4ED256D_C173_47E8_8DA9_9C8C20CB2073__INCLUDED_
  6. #if _MSC_VER > 1000
  7. #pragma once
  8. #endif // _MSC_VER > 1000
  9. class CFirewallAppView : public CFormView
  10. {
  11. protected: // create from serialization only
  12. CFirewallAppView();
  13. DECLARE_DYNCREATE(CFirewallAppView)
  14. public:
  15. //{{AFX_DATA(CFirewallAppView)
  16. enum { IDD = IDD_FIREWALLAPP_FORM };
  17. CListCtrl m_rules;
  18. //}}AFX_DATA
  19. // Attributes
  20. public:
  21. CFirewallAppDoc* GetDocument();
  22. // Operations
  23. public:
  24. // Overrides
  25. // ClassWizard generated virtual function overrides
  26. //{{AFX_VIRTUAL(CFirewallAppView)
  27. public:
  28. virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
  29. protected:
  30. virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
  31. virtual void OnInitialUpdate(); // called first time after construct
  32. virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
  33. virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
  34. virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
  35. virtual void OnPrint(CDC* pDC, CPrintInfo* pInfo);
  36. //}}AFX_VIRTUAL
  37. // Implementation
  38. public:
  39. void UpdateList();
  40. virtual ~CFirewallAppView();
  41. #ifdef _DEBUG
  42. virtual void AssertValid() const;
  43. virtual void Dump(CDumpContext& dc) const;
  44. #endif
  45. protected:
  46. // Generated message map functions
  47. protected:
  48. void AddRuleToList(unsigned long srcIp, 
  49.    unsigned long srcMask,
  50.    unsigned short srcPort, 
  51.    unsigned long dstIp, 
  52.    unsigned long dstMask,
  53.    unsigned short dstPort, 
  54.    unsigned int protocol, 
  55.    int action);
  56. //{{AFX_MSG(CFirewallAppView)
  57. // NOTE - the ClassWizard will add and remove member functions here.
  58. //    DO NOT EDIT what you see in these blocks of generated code !
  59. //}}AFX_MSG
  60. DECLARE_MESSAGE_MAP()
  61. };
  62. #ifndef _DEBUG  // debug version in FirewallAppView.cpp
  63. inline CFirewallAppDoc* CFirewallAppView::GetDocument()
  64.    { return (CFirewallAppDoc*)m_pDocument; }
  65. #endif
  66. /////////////////////////////////////////////////////////////////////////////
  67. //{{AFX_INSERT_LOCATION}}
  68. // Microsoft Visual C++ will insert additional declarations immediately before the previous line.
  69. #endif // !defined(AFX_FIREWALLAPPVIEW_H__A4ED256D_C173_47E8_8DA9_9C8C20CB2073__INCLUDED_)