adjacenttable.h

来自「一个模拟flex的应用程序 主要实现词法分析 语义分析」· C头文件 代码 · 共 30 行

H
30
字号
#ifndef ADJACENT_TABLE_HEADER#define ADJACENT_TABLE_HEADER#include"Vertex.h"#include"Edge.h"using namespace std;class AdjacentTable
{
	private:
		Vertex *start;
		int numOfVertices;
		int numOfEdges;
	public:
		AdjacentTable();
		int GetValueByPos(int pos) const;
		int GetPosByValue(int value) const;
		char GetWeightByPos(int v1, int v2) const;
		char GetWeightByValue(int value1, int value2) const;
		void SetValue(int value, int pos);
		void InsertVertex(int value);
		void InsertEdgeByPos(int v1, int v2, char weight);
		void InsertEdgeByValue(int value1, int value2, char weight);
		void RemoveAllEdges(void);
		void Clear(void);
		int* Closure(int *T);
		int* Move(int *T, char ch);
		void OutputNFA(void);          ~AdjacentTable();
};#endif

⌨️ 快捷键说明

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