pathfinder.h

来自「我用的是arcengine开发,在几何网络中寻找最短路径.」· C头文件 代码 · 共 45 行

H
45
字号
// PathFinder.h: interface for the CPathFinder class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_PATHFINDER_H__B836C429_38F5_4E26_9F01_F0D8543CE068__INCLUDED_)
#define AFX_PATHFINDER_H__B836C429_38F5_4E26_9F01_F0D8543CE068__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

#ifdef		EXPORT_YUNRES
#define		EXPORTCLASS	__declspec(dllexport)
#else
#define		EXPORTCLASS	__declspec(dllimport)
#endif

class EXPORTCLASS CPathFinder  
{
public:
	IPointCollectionPtr GetPoints();
	void ResetWorkspace();
	void CloseWorkspace();
	int SolvePath(CString WeightName);
	double GetPathCost();
	void GetPathPolyLine(IPolyline **pVal,CArray<IFeature *,IFeature *> &arrLineFeature);
	void PutPoints(IPointCollection *newVal);
	void OpenFeatureDatasetNetwork(IFeatureDataset* FeatureDS);
	CPathFinder();
	virtual ~CPathFinder();
	IMapPtr	  m_pMap;
private:
	IPolylinePtr           m_pPolyline;
	double                 m_dblPathCost;
	IEnumNetEIDPtr         m_pEnumNetEID_Junctions;
    IEnumNetEIDPtr         m_pEnumNetEID_Edges;
	IPointCollectionPtr    m_pPoints;
	IGeometricNetworkPtr   m_pGeometricNetwork;
	IPointToEIDPtr	       m_pPointToEID;

	bool InitializeNetworkAndMap(IFeatureDatasetPtr FeatureDataset);
};

#endif // !defined(AFX_PATHFINDER_H__B836C429_38F5_4E26_9F01_F0D8543CE068__INCLUDED_)

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?