本文整理汇总了C++中TILx::GetStrToEoln方法的典型用法代码示例。如果您正苦于以下问题:C++ TILx::GetStrToEoln方法的具体用法?C++ TILx::GetStrToEoln怎么用?C++ TILx::GetStrToEoln使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类TILx
的用法示例。
在下文中一共展示了TILx::GetStrToEoln方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: ParseAndExeCmLn
void TWebTxtBsTrmSrv::ParseAndExeCmLn(
const int& CltSockId, TILx& Lx, bool& SendMsgToClt, TChA& MsgChA){
SendMsgToClt=true;
if (Lx.UcStr=="TRALALA"){
MsgChA+=TStr("Hopsasa")+Lx.GetStrToEoln()+"!\r\n";
} else
if (Lx.UcStr=="SYSECHO"){
TStr SysMsgStr=Lx.GetStrToEoln(true).GetUc();
if (SysMsgStr=="ACCEPT"){
MsgChA+="\r\n";
MsgChA+=TStr(" Welcome at WebBird/WebFly Index Engine (V1.0)!\r\n");
//MsgChA+=TStr(" From:")+GetPeerIpNum()(CltSockId)+"\r\n";
MsgChA+=TStr(" Time:")+TSecTm::GetCurTm().GetStr()+"\r\n";
MsgChA+="\r\n";
} else
if (SysMsgStr=="CLOSE"){
SendMsgToClt=false;
} else {
MsgChA+=SysMsgStr; MsgChA+="\r\n";
}
} else
if (Lx.UcStr=="ECHO"){
MsgChA+=Lx.GetStrToEoln(true);
} else
if (Lx.UcStr=="HELP"){
Lx.GetSym(syEof);
MsgChA+=GetHelpStr();
} else
if (Lx.UcStr=="MEM"){
Lx.GetSym(syEof);
PSysMemStat MemStat=PSysMemStat(new TSysMemStat());
MsgChA+=MemStat->GetInfoStr();
} else
if (Lx.UcStr=="QUIT"){
Lx.GetSym(syEof);
CloseClt(CltSockId);
SendMsgToClt=false;
} else
if (Lx.UcStr=="SET"){
PPp WebTxtBsPp=WebTxtBs->GetPp();
Lx.GetSym(syIdStr, syEof);
if (Lx.Sym==syIdStr){
TStr PpNm=Lx.UcStr; PPp Pp;
if (WebTxtBsPp->IsPp(PpNm, Pp)){
Lx.GetSym(syIdStr, syQStr, syInt, syEof);
if (Lx.Sym==syEof){
MsgChA+=Pp->GetStr();
} else
if (((Lx.Sym==syIdStr)||(Lx.Sym==syQStr))&&(Pp->GetTag()==ptStr)){
Pp->PutValStr(Lx.Str);
} else
if ((Lx.Sym==syInt)&&(Pp->GetTag()==ptInt)){
Pp->PutValInt(Lx.Int);
} else {
MsgChA+="Error: Bad value type.\r\n";
}
} else {
MsgChA+=TStr("Error: Property '")+PpNm+"' not defined.\r\n";
}
} else
if (Lx.Sym==syEof){
MsgChA+=WebTxtBsPp->GetStr();
} else {
Fail;
}
} else
if (Lx.UcStr=="NEW"){
Lx.GetSym(syEof);
TStr FPath; TStr Nm; GetWebTxtBsPp_FPath_Nm(FPath, Nm);
WebTxtBs->TxtBsNew(Nm, FPath);
} else
if (Lx.UcStr=="OPEN"){
Lx.GetSym(syEof);
TStr FPath; TStr Nm; GetWebTxtBsPp_FPath_Nm(FPath, Nm);
WebTxtBs->TxtBsOpenForUpdate(Nm, FPath);
} else
if (Lx.UcStr=="CLOSE"){
Lx.GetSym(syEof);
WebTxtBs->TxtBsClose();
} else
if (Lx.UcStr=="DEL"){
Lx.GetSym(syEof);
TStr FPath; TStr Nm; GetWebTxtBsPp_FPath_Nm(FPath, Nm);
WebTxtBs->TxtBsDel(Nm, FPath);
} else
if (Lx.UcStr=="START"){
Lx.GetSym(syEof);
TStr FPath; TStr Nm; GetWebTxtBsPp_FPath_Nm(FPath, Nm);
TStr WebFilterFNm; GetWebTxtBsPp_WebFilterFNm(WebFilterFNm);
WebTxtBs->FetchStart(Nm, FPath, WebFilterFNm);
} else
if (Lx.UcStr=="STOP"){
Lx.GetSym(syEof);
WebTxtBs->FetchStop();
} else
if (Lx.UcStr=="CONT"){
Lx.GetSym(syEof);
TStr FPath; TStr Nm; GetWebTxtBsPp_FPath_Nm(FPath, Nm);
WebTxtBs->FetchContinue(Nm, FPath);
} else
//.........这里部分代码省略.........