SNAP Library 6.0, Developer Reference
2020-12-09 16:24:20
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
|
#include <lx.h>
Public Member Functions | |
TILx (const PSIn &_SIn, const TFSet &OptSet=TFSet(), const TLxChDefTy &ChDefTy=lcdtUsAscii) | |
TILx & | operator= (const TILx &) |
void | SetOpt (const int &Opt, const bool &Val) |
TLxSym | AddRw (const TStr &Str) |
TLxSym | GetRw (const TStr &Str) |
PSIn | GetSIn (const char &SepCh) |
int | GetLnN () const |
bool | IsBof () const |
bool | IsEof () const |
TLxSym | GetSym (const TFSet &Expect) |
TLxSym | GetSym () |
TLxSym | GetSym (const TLxSym &Sym) |
TLxSym | GetSym (const TLxSym &Sym1, const TLxSym &Sym2) |
TLxSym | GetSym (const TLxSym &Sym1, const TLxSym &Sym2, const TLxSym &Sym3) |
TLxSym | GetSym (const TLxSym &Sym1, const TLxSym &Sym2, const TLxSym &Sym3, const TLxSym &Sym4) |
bool | GetBool () |
int | GetInt () |
double | GetFlt () |
TStr | GetStr (const TStr &_Str=TStr()) |
TStr | GetIdStr (const TStr &IdStr=TStr()) |
TStr | GetQStr (const TStr &QStr=TStr()) |
void | GetEoln () |
TStr | GetStrToCh (const char &ToCh) |
TStr | GetStrToEolnOrCh (const char &ToCh) |
TStr | GetStrToEoln (const bool &DoTrunc=false) |
TStr | GetStrToEolnAndCh (const char &ToCh) |
void | SkipToEoln () |
void | SkipToSym (const TLxSym &SkipToSym) |
void | PutSym (const TILxSymSt &SymSt) |
void | PutSym () |
TLxSym | PeekSym () |
TLxSym | PeekSym (const int &Syms) |
TStr | GetSymStr () const |
TStr | GetFPosStr () const |
bool | IsVar (const TStr &VarNm) |
void | GetVar (const TStr &VarNm, const bool &LBracket=false, const bool &NewLn=false) |
void | GetVarEnd (const bool &RBracket=false, const bool &NewLn=false) |
bool | PeekVarEnd (const bool &RBracket=false, const bool &NewLn=false) |
bool | GetVarBool (const TStr &VarNm, const bool &NewLn=true) |
int | GetVarInt (const TStr &VarNm, const bool &NewLn=true) |
double | GetVarFlt (const TStr &VarNm, const bool &NewLn=true) |
TStr | GetVarStr (const TStr &VarNm, const bool &NewLn=true) |
TSecTm | GetVarSecTm (const TStr &VarNm, const bool &NewLn=true) |
void | GetVarBoolV (const TStr &VarNm, TBoolV &BoolV, const bool &NewLn=true) |
void | GetVarIntV (const TStr &VarNm, TIntV &IntV, const bool &NewLn=true) |
void | GetVarFltV (const TStr &VarNm, TFltV &FltV, const bool &NewLn=true) |
void | GetVarStrV (const TStr &VarNm, TStrV &StrV, const bool &NewLn=true) |
void | GetVarStrPrV (const TStr &VarNm, TStrPrV &StrPrV, const bool &NewLn=true) |
void | GetVarStrVV (const TStr &VarNm, TVec< TStrV > &StrVV, const bool &NewLn=true) |
Static Public Member Functions | |
static TStr | GetQStr (const TStr &Str, const bool &QuoteP, const char &QuoteCh) |
static void | GetLnV (const TStr &FNm, TStrV &LnV) |
Public Attributes | |
TLxSym | Sym |
TChA | Str |
TChA | UcStr |
TChA | CmtStr |
bool | Bool |
int | Int |
double | Flt |
int | SymLnN |
int | SymLnChN |
int | SymChN |
bool | QuoteP |
char | QuoteCh |
Private Member Functions | |
char | GetCh () |
char | GetChX () |
Private Attributes | |
PLxChDef | ChDef |
PSIn | SIn |
TSIn & | RSIn |
char | PrevCh |
char | Ch |
int | LnN |
int | LnChN |
int | ChN |
TSStack< TILxSymSt > | PrevSymStStack |
TStrIntH | RwStrH |
bool | IsCmtAlw |
bool | IsRetEoln |
bool | IsSigNum |
bool | IsUniStr |
bool | IsCsSens |
bool | IsExcept |
bool | IsTabSep |
bool | IsList |
TILx::TILx | ( | const PSIn & | _SIn, |
const TFSet & | OptSet = TFSet() , |
||
const TLxChDefTy & | ChDefTy = lcdtUsAscii |
||
) |
Definition at line 300 of file lx.cpp.
References THash< TKey, TDat, THashFunc >::AddDat(), ChDef, TLxChDef::GetUcStr(), IAssert, THash< TKey, TDat, THashFunc >::IsKey(), THash< TKey, TDat, THashFunc >::Len(), RwStrH, syMnRw, syMxRw, and UcStr.
|
inline |
Definition at line 180 of file lx.h.
References Bool, GetSym(), and syBool.
Referenced by GetVarBool().
|
inlineprivate |
Definition at line 140 of file lx.h.
References Assert, Ch, TSIn::Eof(), TCh::EofCh, and TSIn::GetCh().
Referenced by GetSIn(), GetStrToCh(), GetStrToEoln(), GetStrToEolnAndCh(), GetStrToEolnOrCh(), GetSym(), and SkipToEoln().
|
inlineprivate |
|
inline |
Definition at line 189 of file lx.h.
References GetSym(), and syEoln.
Referenced by GetVar(), GetVarBool(), GetVarBoolV(), GetVarEnd(), GetVarFlt(), GetVarFltV(), GetVarInt(), GetVarIntV(), GetVarSecTm(), GetVarStr(), GetVarStrPrV(), GetVarStrV(), and GetVarStrVV().
|
inline |
Definition at line 182 of file lx.h.
References Flt, GetSym(), and syFlt.
Referenced by GetVarFlt().
TStr TILx::GetFPosStr | ( | ) | const |
Definition at line 607 of file lx.cpp.
References TSBase::GetSNm(), TInt::GetStr(), LnChN, LnN, and SIn.
Referenced by GetSym().
Definition at line 185 of file lx.h.
References GetSym(), IAssert, Str, and syIdStr.
Referenced by GetVar(), GetVarBool(), GetVarFlt(), GetVarInt(), GetVarSecTm(), and GetVarStr().
|
inline |
Definition at line 181 of file lx.h.
References GetSym(), Int, and syInt.
Referenced by GetVarInt(), TRnd::LoadTxt(), and TSecTm::LoadTxt().
|
inline |
Definition at line 687 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), Ch, TChA::Clr(), TVec< TVal, TSizeTy >::Clr(), TCh::CrCh, TChA::Empty(), TFIn::Eof(), TFIn::GetCh(), TCh::LfCh, PrevCh, and SIn.
Definition at line 187 of file lx.h.
References GetSym(), IAssert, Str, and syQStr.
Referenced by GetVarStr(), and GetVarStrPrV().
Definition at line 615 of file lx.cpp.
References Ch, ChN, TStr::CStr(), TStr::Len(), QuoteCh, and Str.
Definition at line 163 of file lx.h.
References THash< TKey, TDat, THashFunc >::GetDat().
PSIn TILx::GetSIn | ( | const char & | SepCh | ) |
Definition at line 309 of file lx.cpp.
References Ch, TSStack< TVal >::Empty(), TCh::EofCh, GetCh(), IAssert, PrevSymStStack, and SIn.
TStr TILx::GetStrToCh | ( | const char & | ToCh | ) |
Definition at line 539 of file lx.cpp.
References TChA::AddCh(), Ch, ChDef, TChA::Clr(), TCh::EofCh, GetCh(), TLxChDef::GetUc(), Str, Sym, syStr, and UcStr.
TStr TILx::GetStrToEoln | ( | const bool & | DoTrunc = false | ) |
Definition at line 553 of file lx.cpp.
References TChA::AddCh(), Ch, ChDef, TChA::Clr(), TCh::CrCh, TCh::EofCh, GetCh(), TLxChDef::GetUc(), TCh::LfCh, Str, Sym, syStr, TChA::ToTrunc(), and UcStr.
TStr TILx::GetStrToEolnAndCh | ( | const char & | ToCh | ) |
Definition at line 561 of file lx.cpp.
References TChA::AddCh(), Ch, ChDef, ChN, TChA::Clr(), TCh::CrCh, TCh::EofCh, forever, GetCh(), TLxChDef::GetUc(), IsBof(), TCh::LfCh, PrevCh, Str, Sym, syStr, and UcStr.
TStr TILx::GetStrToEolnOrCh | ( | const char & | ToCh | ) |
Definition at line 546 of file lx.cpp.
References TChA::AddCh(), Ch, ChDef, TChA::Clr(), TCh::CrCh, TCh::EofCh, GetCh(), TLxChDef::GetUc(), TCh::LfCh, Str, Sym, syStr, and UcStr.
Definition at line 315 of file lx.cpp.
References TChA::AddCh(), Bool, Ch, ChDef, ChN, TChA::Clr(), CmtStr, TCh::CrCh, TChA::CStr(), EAssertR, TFSet::Empty(), THash< TKey, TDat, THashFunc >::Empty(), TSStack< TVal >::Empty(), TUnicode::EncodeUtf8(), TCh::EofCh, Fail, Flt, forever, GetCh(), GetFPosStr(), TCh::GetHex(), THash< TKey, TDat, THashFunc >::GetKeyId(), GetSym(), GetSymStr(), TLxChDef::GetUc(), TBool::GetValFromStr(), IAssert, TFSet::In(), Int, TLxChDef::IsAlNum(), TLxChDef::IsAlpha(), IsBof(), IsCmtAlw, IsCsSens, IsExcept, TCh::IsHex(), TLxChDef::IsNum(), IsRetEoln, IsSigNum, TLxChDef::IsSpace(), IsTabSep, TLxChDef::IsTerm(), IsUniStr, TBool::IsValStr(), TCh::LfCh, LnChN, LnN, TChA::Pop(), TSStack< TVal >::Pop(), PrevSymStStack, QuoteCh, QuoteP, TILxSymSt::Restore(), RwStrH, Str, syAmpersand, syAsterisk, syBool, syColon, syComma, syDColon, syDPeriod, syEof, syEoln, syEq, syExclamation, syFlt, syGEq, syGtr, syHash, syIdStr, syInt, syLBrace, syLBracket, syLEq, syLn, syLParen, syLss, Sym, SymChN, syMinus, SymLnChN, SymLnN, syNEq, syPercent, syPeriod, syPlus, syQStr, syQuestion, syRBrace, syRBracket, syRParen, sySemicolon, sySlash, syStr, syTab, syUndef, syVBar, TCh::TabCh, TSStack< TVal >::Top(), TChA::Trunc(), and UcStr.
Referenced by TJsonVal::GetValFromLx(), TJsonVal::GetValFromSIn(), and TLAMisc::LoadMatlabTFltVV().
|
inline |
Definition at line 171 of file lx.h.
References GetSym().
Referenced by GetBool(), GetEoln(), GetFlt(), GetIdStr(), GetInt(), GetQStr(), GetStr(), GetSym(), GetVar(), GetVarBool(), GetVarBoolV(), GetVarEnd(), GetVarFlt(), GetVarFltV(), GetVarInt(), GetVarIntV(), GetVarSecTm(), GetVarStr(), GetVarStrPrV(), GetVarStrV(), GetVarStrVV(), IsVar(), PeekSym(), and SkipToSym().
Definition at line 172 of file lx.h.
References GetSym().
Referenced by GetSym().
Definition at line 173 of file lx.h.
References GetSym().
Definition at line 175 of file lx.h.
References GetSym().
|
inline |
Definition at line 177 of file lx.h.
References GetSym().
TStr TILx::GetSymStr | ( | ) | const |
|
inline |
Definition at line 209 of file lx.h.
References GetEoln(), GetIdStr(), GetSym(), syColon, and syLBracket.
Referenced by GetVarBoolV(), GetVarFltV(), GetVarIntV(), GetVarStrPrV(), GetVarStrV(), and GetVarStrVV().
|
inline |
Definition at line 632 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), Bool, TVec< TVal, TSizeTy >::Clr(), GetEoln(), GetSym(), GetVar(), syBool, syQStr, and syRBracket.
|
inline |
|
inline |
Definition at line 648 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), TVec< TVal, TSizeTy >::Clr(), Flt, GetEoln(), GetSym(), GetVar(), syFlt, and syRBracket.
|
inline |
Definition at line 222 of file lx.h.
References GetEoln(), GetIdStr(), GetInt(), GetSym(), Int, and syColon.
Referenced by TMBlobBs::LoadMain().
Definition at line 640 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), TVec< TVal, TSizeTy >::Clr(), GetEoln(), GetSym(), GetVar(), Int, syInt, and syRBracket.
Definition at line 231 of file lx.h.
References GetEoln(), GetIdStr(), GetSym(), TSecTm::LoadTxt(), and syColon.
Definition at line 228 of file lx.h.
References GetEoln(), GetIdStr(), GetQStr(), GetSym(), Str, and syColon.
Referenced by TMBlobBs::LoadMain().
Definition at line 664 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), TVec< TVal, TSizeTy >::Clr(), GetEoln(), GetQStr(), GetSym(), GetVar(), syLBracket, and syRBracket.
Definition at line 656 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), TVec< TVal, TSizeTy >::Clr(), GetEoln(), GetSym(), GetVar(), Str, syQStr, and syRBracket.
Definition at line 675 of file lx.cpp.
References TVec< TVal, TSizeTy >::Add(), TVec< TVal, TSizeTy >::Clr(), GetEoln(), GetSym(), GetVar(), TVec< TVal, TSizeTy >::Last(), Str, syLBracket, syQStr, and syRBracket.
|
inline |
|
inline |
|
inline |
|
inline |
Definition at line 200 of file lx.h.
References GetSym(), and PutSym().
Referenced by PeekVarEnd().
TLxSym TILx::PeekSym | ( | const int & | Syms | ) |
Definition at line 580 of file lx.cpp.
References TSStack< TVal >::Empty(), GetSym(), TSStack< TVal >::Pop(), TSStack< TVal >::Push(), PutSym(), TILxSymSt::Restore(), Sym, and TSStack< TVal >::Top().
|
inline |
|
inline |
Definition at line 198 of file lx.h.
References TSStack< TVal >::Push().
|
inline |
Definition at line 199 of file lx.h.
References TSStack< TVal >::Push().
Referenced by IsVar(), and PeekSym().
void TILx::SetOpt | ( | const int & | Opt, |
const bool & | Val | ||
) |
Definition at line 286 of file lx.cpp.
References Fail, iloCmtAlw, iloCsSens, iloExcept, iloList, iloRetEoln, iloSigNum, iloTabSep, iloUniStr, IsCmtAlw, IsCsSens, IsExcept, IsList, IsRetEoln, IsSigNum, IsTabSep, and IsUniStr.
Referenced by TILx().
void TILx::SkipToEoln | ( | ) |
|
inline |
bool TILx::Bool |
Definition at line 151 of file lx.h.
Referenced by GetBool(), GetSym(), GetVarBool(), GetVarBoolV(), and TILxSymSt::Restore().
|
private |
Definition at line 134 of file lx.h.
Referenced by GetCh(), GetChX(), GetLnV(), GetQStr(), GetSIn(), GetStrToCh(), GetStrToEoln(), GetStrToEolnAndCh(), GetStrToEolnOrCh(), GetSym(), and SkipToEoln().
|
private |
Definition at line 131 of file lx.h.
Referenced by AddRw(), GetStrToCh(), GetStrToEoln(), GetStrToEolnAndCh(), GetStrToEolnOrCh(), and GetSym().
|
private |
Definition at line 135 of file lx.h.
Referenced by GetQStr(), GetStrToEolnAndCh(), and GetSym().
TChA TILx::CmtStr |
Definition at line 150 of file lx.h.
Referenced by GetSym(), and TILxSymSt::Restore().
double TILx::Flt |
Definition at line 151 of file lx.h.
Referenced by GetFlt(), GetSym(), TJsonVal::GetValFromLx(), GetVarFlt(), GetVarFltV(), TLAMisc::LoadMatlabTFltVV(), and TILxSymSt::Restore().
int TILx::Int |
Definition at line 151 of file lx.h.
Referenced by GetInt(), GetSym(), GetVarInt(), GetVarIntV(), and TILxSymSt::Restore().
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
Definition at line 135 of file lx.h.
Referenced by GetFPosStr(), and GetSym().
|
private |
Definition at line 135 of file lx.h.
Referenced by GetFPosStr(), GetLnN(), and GetSym().
|
private |
Definition at line 134 of file lx.h.
Referenced by GetLnV(), and GetStrToEolnAndCh().
|
private |
|
private |
Definition at line 132 of file lx.h.
Referenced by GetFPosStr(), GetLnV(), and GetSIn().
TChA TILx::Str |
Definition at line 150 of file lx.h.
Referenced by GetIdStr(), GetQStr(), GetStr(), GetStrToCh(), GetStrToEoln(), GetStrToEolnAndCh(), GetStrToEolnOrCh(), GetSym(), GetSymStr(), TJsonVal::GetValFromLx(), GetVarStr(), GetVarStrV(), GetVarStrVV(), and TILxSymSt::Restore().
TLxSym TILx::Sym |
Definition at line 149 of file lx.h.
Referenced by GetStrToCh(), GetStrToEoln(), GetStrToEolnAndCh(), GetStrToEolnOrCh(), GetSym(), GetSymStr(), TJsonVal::GetValFromLx(), TLAMisc::LoadMatlabTFltVV(), PeekSym(), and TILxSymSt::Restore().
int TILx::SymChN |
Definition at line 152 of file lx.h.
Referenced by GetSym(), and TILxSymSt::Restore().
int TILx::SymLnChN |
Definition at line 152 of file lx.h.
Referenced by GetSym(), and TILxSymSt::Restore().
int TILx::SymLnN |
Definition at line 152 of file lx.h.
Referenced by GetSym(), and TILxSymSt::Restore().
TChA TILx::UcStr |
Definition at line 150 of file lx.h.
Referenced by AddRw(), GetStrToCh(), GetStrToEoln(), GetStrToEolnAndCh(), GetStrToEolnOrCh(), GetSym(), and TILxSymSt::Restore().