⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 lit_node.h

📁 我自己写的代码 可能比较简单 我实现了模拟图层的功能
💻 H
字号:
///////////////////////////////////////////////////////////
//  lit_node.h
//  Implementation of the Class lit_node
//  Created on:      18-二月-2009 17:17:34
//  Original author: pyj
///////////////////////////////////////////////////////////

#if !defined(EA_2C926C66_1AD4_4ba6_95C8_8CF78948738A__INCLUDED_)
#define EA_2C926C66_1AD4_4ba6_95C8_8CF78948738A__INCLUDED_

template<class T>
class lit_node
{

public:
	lit_node()
	{
		preNode = NULL;
		nextNode = NULL;
	};
	lit_node(T& t):preNode(NULL),nextNode(NULL),value(t){};
	virtual ~lit_node(){};
	lit_node<T>* next(){
		return  nextNode;
	}
	bool next(lit_node<T>* t){
		if (t)
		{
			nextNode = t;
			return true;
		}
		return false;
	}
	bool pre(lit_node<T>* t){
		if (t)
		{
			preNode = t;
			return true;
		}

		return false;
	}
	lit_node<T>* pre(){

		return  preNode;
	}
	void set_value(T& t){
		value  = t;

	}
	T get_value(){

		return  value;
	}

private:
	lit_node<T>* nextNode;
	lit_node<T>* preNode;
	T value;

};
#endif // !defined(EA_2C926C66_1AD4_4ba6_95C8_8CF78948738A__INCLUDED_)

⌨️ 快捷键说明

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