cnstream.h

来自「linux 上http email 协议分析程序 主要能够处理大数据量的主干网」· C头文件 代码 · 共 51 行

H
51
字号
#ifndef _MIME_FILE_H
#define _MIME_FILE_H

#include "Consts.h"
#include "Stru.h"
#include "Utility.h"
class Cmimestream
{
public:
	//根据配置分配内存
	Cmimestream();
	~Cmimestream();
	void init(int ilen,char *szdata);
		
	//读入逻辑行
	int tmdgetLine(char *buf);
	int tmdgetLine(char *buf,int buflen);

	int getLine(char *buf);
	int getLine(char *buf,int buflen);
	//int getLine(char *&buf);
	void gotoNextLine();
	char *gotoMarker(char *marker);
	void gotoEndPos();
	bool endofStream();
	void  goaHead(int len);

	char *getCurPos();
	char *getEndPos();
	char *getEndEmailBodyPos();
	char *posBoudary(char *szbd);
	char *posEndBody();
	
	//void saveFile(struct ST_TCP_STREAM *);

private:
	/*
	int  m_ibuflen;
	char *m_szbuf;
	int  m_ilenrecv;
	*/
	char *m_curpos;
	char *m_endpos;
	
};



#endif

⌨️ 快捷键说明

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