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

📄 msglist.cpp

📁 电梯仿真系统的实现
💻 CPP
字号:
// MsgList.cpp: implementation of the CMsgList class.
//
//////////////////////////////////////////////////////////////////////

#include "stdafx.h"
#include "ESystem.h"
#include "MsgList.h"

#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif

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

CMsgList::CMsgList()
{

}

CMsgList::~CMsgList()
{

}

bool CMsgList::RemoveByPID(int pid)
{
	CMsgList::iterator it;
	CMessage* tmp;
	for(it = begin();it!=end();it++)
	{
		tmp = *it;
		if(tmp->PID == pid)
		{
			remove(tmp);
			return true;
		}
	}
	TRACE("消息队列中没有该乘客P%d,指令有误.\n",pid);
	return false;
}

⌨️ 快捷键说明

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