SNAP Library 3.0, User Reference  2016-07-20 17:56:49
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
TWCh Class Reference

#include <wch.h>

Public Member Functions

 TWCh ()
 
 TWCh (const uchar &_LsVal)
 
 TWCh (const uchar &_MsVal, const uchar &_LsVal)
 
 TWCh (const int &_MsVal, const int &_LsVal)
 
 operator char () const
 
 TWCh (TSIn &SIn)
 
void Save (TSOut &SOut) const
 
TWChoperator= (const TWCh &WCh)
 
bool operator== (const TWCh &WCh) const
 
bool operator< (const TWCh &WCh) const
 
int GetMemUsed () const
 
int GetPrimHashCd () const
 
int GetSecHashCd () const
 
char GetCh () const
 
void SaveTxt (const PSOut &SOut) const
 

Static Public Member Functions

static TWCh LoadTxt (const PSIn &SIn)
 

Static Public Attributes

static const TWCh Mn
 
static const TWCh Mx
 
static const int Vals =0x10000
 
static const TWCh StartWCh
 
static const TWCh TabWCh
 
static const TWCh LfWCh
 
static const TWCh CrWCh
 
static const TWCh SpaceWCh
 

Private Attributes

uchar MsVal
 
uchar LsVal
 

Detailed Description

Definition at line 3 of file wch.h.

Constructor & Destructor Documentation

TWCh::TWCh ( )
inline

Definition at line 12 of file wch.h.

12 : MsVal(0), LsVal(0){}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
TWCh::TWCh ( const uchar _LsVal)
inline

Definition at line 13 of file wch.h.

13 : MsVal(0), LsVal(_LsVal){}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
TWCh::TWCh ( const uchar _MsVal,
const uchar _LsVal 
)
inline

Definition at line 14 of file wch.h.

14  :
15  MsVal(_MsVal), LsVal(_LsVal){}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
TWCh::TWCh ( const int &  _MsVal,
const int &  _LsVal 
)
inline

Definition at line 16 of file wch.h.

16  :
17  MsVal(uchar(_MsVal)), LsVal(uchar(_LsVal)){}
uchar LsVal
Definition: wch.h:6
unsigned char uchar
Definition: bd.h:10
uchar MsVal
Definition: wch.h:5
TWCh::TWCh ( TSIn SIn)
inline

Definition at line 19 of file wch.h.

19 {SIn.Load(MsVal); SIn.Load(LsVal);}
void Load(bool &Bool)
Definition: fl.h:84
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5

Member Function Documentation

char TWCh::GetCh ( ) const
inline

Definition at line 33 of file wch.h.

33  {
34  if (MsVal==TCh::NullCh){return LsVal;} else {return '#';}}
static const char NullCh
Definition: dt.h:943
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
int TWCh::GetMemUsed ( ) const
inline

Definition at line 28 of file wch.h.

28 {return sizeof(MsVal)+sizeof(LsVal);}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
int TWCh::GetPrimHashCd ( ) const
inline

Definition at line 30 of file wch.h.

30 {return LsVal;}
uchar LsVal
Definition: wch.h:6
int TWCh::GetSecHashCd ( ) const
inline

Definition at line 31 of file wch.h.

31 {return MsVal;}
uchar MsVal
Definition: wch.h:5
static TWCh TWCh::LoadTxt ( const PSIn SIn)
inlinestatic

Definition at line 36 of file wch.h.

36  {
37  uchar LsVal=SIn->GetCh(); uchar MsVal=SIn->GetCh();
38  return TWCh(MsVal, LsVal);}
TWCh()
Definition: wch.h:12
uchar LsVal
Definition: wch.h:6
unsigned char uchar
Definition: bd.h:10
uchar MsVal
Definition: wch.h:5
virtual char GetCh()=0
TWCh::operator char ( ) const
inline

Definition at line 18 of file wch.h.

18 {return LsVal;}
uchar LsVal
Definition: wch.h:6
bool TWCh::operator< ( const TWCh WCh) const
inline

Definition at line 26 of file wch.h.

26  {
27  return (MsVal<WCh.MsVal)||((MsVal==WCh.MsVal)&&(LsVal<WCh.LsVal));}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
TWCh& TWCh::operator= ( const TWCh WCh)
inline

Definition at line 22 of file wch.h.

22  {
23  MsVal=WCh.MsVal; LsVal=WCh.LsVal; return *this;}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
bool TWCh::operator== ( const TWCh WCh) const
inline

Definition at line 24 of file wch.h.

24  {
25  return (MsVal==WCh.MsVal)&&(LsVal==WCh.LsVal);}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5
void TWCh::Save ( TSOut SOut) const
inline

Definition at line 20 of file wch.h.

20 {SOut.Save(MsVal); SOut.Save(MsVal);}
void Save(const bool &Bool)
Definition: fl.h:173
uchar MsVal
Definition: wch.h:5
void TWCh::SaveTxt ( const PSOut SOut) const
inline

Definition at line 39 of file wch.h.

39  {
40  SOut->PutCh(MsVal); SOut->PutCh(LsVal);}
uchar LsVal
Definition: wch.h:6
uchar MsVal
Definition: wch.h:5

Member Data Documentation

const TWCh TWCh::CrWCh
static

Definition at line 45 of file wch.h.

const TWCh TWCh::LfWCh
static

Definition at line 44 of file wch.h.

uchar TWCh::LsVal
private

Definition at line 6 of file wch.h.

const TWCh TWCh::Mn
static

Definition at line 8 of file wch.h.

uchar TWCh::MsVal
private

Definition at line 5 of file wch.h.

const TWCh TWCh::Mx
static

Definition at line 9 of file wch.h.

const TWCh TWCh::SpaceWCh
static

Definition at line 46 of file wch.h.

const TWCh TWCh::StartWCh
static

Definition at line 42 of file wch.h.

const TWCh TWCh::TabWCh
static

Definition at line 43 of file wch.h.

const int TWCh::Vals =0x10000
static

Definition at line 10 of file wch.h.


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