recordlist.cpp

来自「用面向连接的TCP实现学生信息的管理」· C++ 代码 · 共 30 行

CPP
30
字号
// RecordList.cpp: implementation of the RecordList class.
//
//////////////////////////////////////////////////////////////////////

#include "RecordList.h"

//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////

RecordList::RecordList()
{

}

void RecordList::clear()
{
	iterator it=this->begin();
	for(it=this->begin(); it!= this->end();it++)
		delete *it;                              //释放指针指向的对象
	list<Record*>::clear();                      //释放指针
}

RecordList::~RecordList()
{
	clear(); 

}

⌨️ 快捷键说明

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