SNAP Library 6.0, User Reference  2020-12-09 16:24:20
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
TTypeNm< Type > Class Template Reference

#include <ut.h>

Inherits TStr.

Public Member Functions

 TTypeNm ()
 
- Public Member Functions inherited from TStr
 TStr ()
 
 TStr (const TStr &Str)
 
 TStr (const TChA &ChA)
 
 TStr (const TSStr &SStr)
 
 TStr (const char *CStr)
 
 TStr (const char &Ch)
 
 TStr (const TMem &Mem)
 
 TStr (const PSIn &SIn)
 
 ~TStr ()
 
 TStr (TSIn &SIn, const bool &IsSmall=false)
 
void Load (TSIn &SIn, const bool &IsSmall=false)
 
void Save (TSOut &SOut, const bool &IsSmall=false) const
 
void LoadXml (const PXmlTok &XmlTok, const TStr &Nm)
 
void SaveXml (TSOut &SOut, const TStr &Nm) const
 
TStroperator= (const TStr &Str)
 
TStroperator= (const TChA &ChA)
 
TStroperator= (const char *CStr)
 
TStroperator= (const char &Ch)
 
TStroperator+= (const TStr &Str)
 
TStroperator+= (const char *CStr)
 
TStroperator/ (const int &N)
 
bool operator== (const TStr &Str) const
 
bool operator== (const char *CStr) const
 
bool operator!= (const char *CStr) const
 
bool operator< (const TStr &Str) const
 
char operator[] (const int &ChN) const
 
int GetMemUsed () const
 
char * operator() ()
 
const char * operator() () const
 
char * CStr ()
 
const char * CStr () const
 
void PutCh (const int &ChN, const char &Ch)
 
char GetCh (const int &ChN) const
 
char LastCh () const
 
void Clr ()
 
int Len () const
 
bool Empty () const
 
bool IsUc () const
 
TStrToUc ()
 
TStr GetUc () const
 
int CmpI (const TStr &Str) const
 
bool EqI (const TStr &Str) const
 
bool IsLc () const
 
TStrToLc ()
 
TStr GetLc () const
 
TStrToCap ()
 
TStr GetCap () const
 
TStrToTrunc ()
 
TStr GetTrunc () const
 
TStrConvUsFromYuAscii ()
 
TStr GetUsFromYuAscii () const
 
TStrToHex ()
 
TStr GetHex () const
 
TStrFromHex ()
 
TStr GetFromHex () const
 
TStr GetSubStr (const int &BChN, const int &EChN) const
 
TStr GetSubStr (const int &BChN) const
 
void InsStr (const int &BChN, const TStr &Str)
 
void DelChAll (const char &Ch)
 
void DelSubStr (const int &BChN, const int &EChN)
 
bool DelStr (const TStr &Str)
 
TStr LeftOf (const char &SplitCh) const
 
TStr LeftOfLast (const char &SplitCh) const
 
TStr RightOf (const char &SplitCh) const
 
TStr RightOfLast (const char &SplitCh) const
 
void SplitOnCh (TStr &LStr, const char &SplitCh, TStr &RStr) const
 
void SplitOnLastCh (TStr &LStr, const char &SplitCh, TStr &RStr) const
 
void SplitOnAllCh (const char &SplitCh, TStrV &StrV, const bool &SkipEmpty=true) const
 
void SplitOnAllAnyCh (const TStr &SplitChStr, TStrV &StrV, const bool &SkipEmpty=true) const
 
void SplitOnWs (TStrV &StrV) const
 
void SplitOnNonAlNum (TStrV &StrV) const
 
void SplitOnStr (const TStr &SplitStr, TStrV &StrV) const
 
void SplitOnStr (TStr &LeftStr, const TStr &MidStr, TStr &RightStr) const
 
TStr Mid (const int &BChN, const int &Chs) const
 
TStr Mid (const int &BChN) const
 
TStr Left (const int &EChN) const
 
TStr Right (const int &BChN) const
 
TStr Slice (int BChN, int EChNP1) const
 
TStr operator() (const int &BChN, const int &EChNP1) const
 
int CountCh (const char &Ch, const int &BChN=0) const
 
int SearchCh (const char &Ch, const int &BChN=0) const
 
int SearchChBack (const char &Ch, int BChN=-1) const
 
int SearchStr (const TStr &Str, const int &BChN=0) const
 
bool IsChIn (const char &Ch) const
 
bool IsStrIn (const TStr &Str) const
 
bool IsPrefix (const char *Str) const
 
bool IsPrefix (const TStr &Str) const
 
bool IsSuffix (const char *Str) const
 
bool IsSuffix (const TStr &Str) const
 
int ChangeCh (const char &SrcCh, const char &DstCh, const int &BChN=0)
 
int ChangeChAll (const char &SrcCh, const char &DstCh)
 
int ChangeStr (const TStr &SrcStr, const TStr &DstStr, const int &BChN=0)
 
int ChangeStrAll (const TStr &SrcStr, const TStr &DstStr, const bool &FromStartP=false)
 
TStr Reverse () const
 
int GetPrimHashCd () const
 
int GetSecHashCd () const
 
bool IsBool (bool &Val) const
 
bool IsInt (const bool &Check, const int &MnVal, const int &MxVal, int &Val) const
 
bool IsInt (int &Val) const
 
bool IsInt () const
 
int GetInt () const
 
int GetInt (const int &DfVal) const
 
bool IsUInt (const bool &Check, const uint &MnVal, const uint &MxVal, uint &Val) const
 
bool IsUInt (uint &Val) const
 
bool IsUInt () const
 
uint GetUInt () const
 
uint GetUInt (const uint &DfVal) const
 
bool IsInt64 (const bool &Check, const int64 &MnVal, const int64 &MxVal, int64 &Val) const
 
bool IsInt64 (int64 &Val) const
 
bool IsInt64 () const
 
int64 GetInt64 () const
 
int64 GetInt64 (const int64 &DfVal) const
 
bool IsUInt64 (const bool &Check, const uint64 &MnVal, const uint64 &MxVal, uint64 &Val) const
 
bool IsUInt64 (uint64 &Val) const
 
bool IsUInt64 () const
 
uint64 GetUInt64 () const
 
uint64 GetUInt64 (const uint64 &DfVal) const
 
bool IsHexInt (const bool &Check, const int &MnVal, const int &MxVal, int &Val) const
 
bool IsHexInt (int &Val) const
 
bool IsHexInt () const
 
int GetHexInt () const
 
int GetHexInt (const int &DfVal) const
 
bool IsHexInt64 (const bool &Check, const int64 &MnVal, const int64 &MxVal, int64 &Val) const
 
bool IsHexInt64 (int64 &Val) const
 
bool IsHexInt64 () const
 
int64 GetHexInt64 () const
 
int64 GetHexInt64 (const int64 &DfVal) const
 
bool IsFlt (const bool &Check, const double &MnVal, const double &MxVal, double &Val, const char &DecDelimCh='.') const
 
bool IsFlt (double &Val) const
 
bool IsFlt () const
 
double GetFlt () const
 
double GetFlt (const double &DfVal) const
 
bool IsWord (const bool &WsPrefixP=true, const bool &FirstUcAllowedP=true) const
 
bool IsWs () const
 
bool IsWcMatch (const int &StrBChN, const TStr &WcStr, const int &WcStrBChN, TStrV &StarStrV, const char &StarCh='*', const char &QuestCh='?') const
 
bool IsWcMatch (const TStr &WcStr, TStrV &StarStrV, const char &StarCh='*', const char &QuestCh='?') const
 
bool IsWcMatch (const TStr &WcStr, const char &StarCh, const char &QuestCh) const
 
bool IsWcMatch (const TStr &WcStr, const int &StarStrN, TStr &StarStr) const
 
bool IsWcMatch (const TStr &WcStr) const
 
TStr GetWcMatch (const TStr &WcStr, const int &StarStrN=0) const
 
TStr GetFPath () const
 
TStr GetFBase () const
 
TStr GetFMid () const
 
TStr GetFExt () const
 
void SaveTxt (const PSOut &SOut) const
 
void SaveTxt (const TStr &FNm) const
 
TStr GetStr () const
 
char * GetCStr () const
 

Static Public Member Functions

static TStr GetNrTypeNm (const TStr &TypeNm)
 
- Static Public Member Functions inherited from TStr
static TStr GetNrFPath (const TStr &FPath)
 
static TStr GetNrFMid (const TStr &FMid)
 
static TStr GetNrFExt (const TStr &FExt)
 
static TStr GetNrNumFExt (const int &FExtN)
 
static TStr GetNrFNm (const TStr &FNm)
 
static TStr GetNrAbsFPath (const TStr &FPath, const TStr &BaseFPath=TStr())
 
static bool IsAbsFPath (const TStr &FPath)
 
static TStr PutFExt (const TStr &FNm, const TStr &FExt)
 
static TStr PutFExtIfEmpty (const TStr &FNm, const TStr &FExt)
 
static TStr PutFBase (const TStr &FNm, const TStr &FBase)
 
static TStr PutFBaseIfEmpty (const TStr &FNm, const TStr &FBase)
 
static TStr AddToFMid (const TStr &FNm, const TStr &ExtFMid)
 
static TStr GetNumFNm (const TStr &FNm, const int &Num)
 
static TStr GetFNmStr (const TStr &Str, const bool &AlNumOnlyP=true)
 
static TStr LoadTxt (const PSIn &SIn)
 
static TStr LoadTxt (const TStr &FNm)
 
static TStrGetChStr (const char &Ch)
 
static TStrGetDChStr (const char &Ch1, const char &Ch2)
 
static TStr GetStr (const TStr &Str, const char *FmtStr)
 
static TStr GetStr (const TStr &Str, const TStr &FmtStr)
 
static TStr GetStr (const TStrV &StrV, const TStr &DelimiterStr)
 
static TStr Fmt (const char *FmtStr,...)
 
static TStr GetSpaceStr (const int &Spaces)
 
static TStr MkClone (const TStr &Str)
 
static TStr GetNullStr ()
 

Detailed Description

template<class Type>
class TTypeNm< Type >

Definition at line 6 of file ut.h.

Constructor & Destructor Documentation

template<class Type >
TTypeNm< Type >::TTypeNm ( )
inline

Definition at line 13 of file ut.h.

13 : TStr(GetNrTypeNm((char*)(typeid(Type).name()))){}
static TStr GetNrTypeNm(const TStr &TypeNm)
Definition: ut.h:8
TStr()
Definition: dt.h:423

Member Function Documentation

template<class Type >
static TStr TTypeNm< Type >::GetNrTypeNm ( const TStr TypeNm)
inlinestatic

Definition at line 8 of file ut.h.

8  {
9  if (TypeNm.IsPrefix("class ")){
10  return TypeNm.GetSubStr(6, TypeNm.Len()-1);}
11  else {return TypeNm;}}
int Len() const
Definition: dt.h:490
bool IsPrefix(const char *Str) const
Definition: dt.cpp:1081
TStr GetSubStr(const int &BChN, const int &EChN) const
Definition: dt.cpp:811

The documentation for this class was generated from the following file: