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

📄 ioport.h

📁 用于仿真系统中多个仿真对象间的内存管理
💻 H
字号:
// IOPort.h: interface for the IOPort class.
//
//////////////////////////////////////////////////////////////////////

#if !defined(AFX_IOPORT_H__69FFA94D_F5C7_4420_9899_C13DF169A8E5__INCLUDED_)
#define AFX_IOPORT_H__69FFA94D_F5C7_4420_9899_C13DF169A8E5__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include<vector>
#include<string>
#include<iostream>
#include "Buffer.h"
#include "ConnectLine.h"
#include "DataStructure.h"
using namespace std;

class IOPort  
{
public:
	void AccomplishIO();	
	void InitOutBuf(int thresh,MemoryPool* pool);
	int GetPortID();
	void SetPortID(const int id);
	void AddConnectLine(ConnectLine* line);
	float* GetBuf();
	void WriteSample(const float sample);
	float ReadSample();
	IOPort(long size,portType type,dataType datatype);
	virtual ~IOPort();
	void SetRelatePortBuf();
private:
	IOPort(const IOPort& rhs);
	IOPort& operator=(const IOPort& rhs);
	void SetInBuffer(Buffer* pbuf);
private:
	
	long port_size;
	portType port_type;
	dataType data_type;
	vector<ConnectLine*> connect_list;
	Buffer* pBuffer;
	int ID;

};

#endif // !defined(AFX_IOPORT_H__69FFA94D_F5C7_4420_9899_C13DF169A8E5__INCLUDED_)

⌨️ 快捷键说明

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