📄 listsegment.cpp
字号:
// ListSegment.cpp: implementation of the CListSegment class.
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "SnmpManager.h"
#include "ListSegment.h"
#ifdef _DEBUG
#undef THIS_FILE
static char THIS_FILE[]=__FILE__;
#define new DEBUG_NEW
#endif
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
CListSegment::CListSegment()
{
}
CListSegment::~CListSegment()
{
}
LineList* CListSegment::create ()
{
LineList *temp;
head = (LineList*)malloc(sizeof(LineList));
// temp->InDigit = 0;
// temp->next = NULL;
return temp;
}
void CListSegment::ReceiveDigit (int Digit)
{
LineList *p1, *p2, *p;
if(head->next == NULL)
{
p1 = (LineList*)malloc(sizeof(LineList));
p1->InDigit = Digit;
p1->next = NULL;
head->next = p1;
}
else
{
p = head;
p2 = (LineList*)malloc(sizeof(LineList));
p2->InDigit = Digit;
p2->next = NULL;
while(p->next != NULL)
{
p = p->next ;
}
p->next = p2;
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -