📄 kmeansview.h
字号:
// kmeansView.h : interface of the CKmeansView class
//
/////////////////////////////////////////////////////////////////////////////
#if !defined(AFX_KMEANSVIEW_H__69FAFC8A_C77A_4075_8FF1_371B12A99569__INCLUDED_)
#define AFX_KMEANSVIEW_H__69FAFC8A_C77A_4075_8FF1_371B12A99569__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include <afxtempl.h>
struct Point
{
float DimData[10];
int flag;
int tflag;
};
class CKmeansView : public CView
{
protected: // create from serialization only
CKmeansView();
DECLARE_DYNCREATE(CKmeansView)
// Attributes
public:
CKmeansDoc* GetDocument();
// Operations
public:
CString m_FileName;
int m_Param;
int m_numOfPoint;
int m_dim;
float m_CheckError;
int m_Rand;
int m_tRand;
CArray <Point,Point&> m_AllPoint;
CArray <Point,Point&> m_CorePoint;
CArray <int,int> iFlag;
CArray <int,int> m_FirRand;
// Overrides
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CKmeansView)
public:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
protected:
virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
//}}AFX_VIRTUAL
// Implementation
public:
float GetEValue(float E);
float GetFirEValue();
void GetAllPoint();
void DrawPoint();
float GetDistance(Point pt1,Point pt2);
void randEx(int MAX,int NUM,int FLAG);
virtual ~CKmeansView();
#ifdef _DEBUG
virtual void AssertValid() const;
virtual void Dump(CDumpContext& dc) const;
#endif
protected:
// Generated message map functions
protected:
//{{AFX_MSG(CKmeansView)
afx_msg void OnExecProgram();
afx_msg void OnExecProgram1();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
#ifndef _DEBUG // debug version in kmeansView.cpp
inline CKmeansDoc* CKmeansView::GetDocument()
{ return (CKmeansDoc*)m_pDocument; }
#endif
/////////////////////////////////////////////////////////////////////////////
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_KMEANSVIEW_H__69FAFC8A_C77A_4075_8FF1_371B12A99569__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -