SNAP Library 2.2, Developer Reference  2014-03-11 19:15:55
SNAP, a general purpose, high performance system for analysis and manipulation of large networks
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
TWCh Class Reference

#include <wch.h>

Collaboration diagram for TWCh:

List of all members.

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.

Referenced by LoadTxt().

: MsVal(0), LsVal(0){}

Here is the caller graph for this function:

TWCh::TWCh ( const uchar _LsVal) [inline]

Definition at line 13 of file wch.h.

: MsVal(0), LsVal(_LsVal){}
TWCh::TWCh ( const uchar _MsVal,
const uchar _LsVal 
) [inline]

Definition at line 14 of file wch.h.

                                                :
    MsVal(_MsVal), LsVal(_LsVal){}
TWCh::TWCh ( const int &  _MsVal,
const int &  _LsVal 
) [inline]

Definition at line 16 of file wch.h.

                                            :
    MsVal(uchar(_MsVal)), LsVal(uchar(_LsVal)){}
TWCh::TWCh ( TSIn SIn) [inline]

Definition at line 19 of file wch.h.

References TSIn::Load(), LsVal, and MsVal.

{SIn.Load(MsVal); SIn.Load(LsVal);}

Here is the call graph for this function:


Member Function Documentation

char TWCh::GetCh ( ) const [inline]

Definition at line 33 of file wch.h.

References LsVal, MsVal, and TCh::NullCh.

                     {
    if (MsVal==TCh::NullCh){return LsVal;} else {return '#';}}
int TWCh::GetMemUsed ( ) const [inline]

Definition at line 28 of file wch.h.

References LsVal, and MsVal.

{return sizeof(MsVal)+sizeof(LsVal);}
int TWCh::GetPrimHashCd ( ) const [inline]

Definition at line 30 of file wch.h.

References LsVal.

{return LsVal;}
int TWCh::GetSecHashCd ( ) const [inline]

Definition at line 31 of file wch.h.

References MsVal.

{return MsVal;}
static TWCh TWCh::LoadTxt ( const PSIn SIn) [inline, static]

Definition at line 36 of file wch.h.

References TSIn::GetCh(), LsVal, MsVal, and TWCh().

                                      {
    uchar LsVal=SIn->GetCh(); uchar MsVal=SIn->GetCh();
    return TWCh(MsVal, LsVal);}

Here is the call graph for this function:

TWCh::operator char ( ) const [inline]

Definition at line 18 of file wch.h.

References LsVal.

{return LsVal;}
bool TWCh::operator< ( const TWCh WCh) const [inline]

Definition at line 26 of file wch.h.

References LsVal, and MsVal.

                                        {
    return (MsVal<WCh.MsVal)||((MsVal==WCh.MsVal)&&(LsVal<WCh.LsVal));}
TWCh& TWCh::operator= ( const TWCh WCh) [inline]

Definition at line 22 of file wch.h.

References LsVal, and MsVal.

                                  {
    MsVal=WCh.MsVal; LsVal=WCh.LsVal; return *this;}
bool TWCh::operator== ( const TWCh WCh) const [inline]

Definition at line 24 of file wch.h.

References LsVal, and MsVal.

                                         {
    return (MsVal==WCh.MsVal)&&(LsVal==WCh.LsVal);}
void TWCh::Save ( TSOut SOut) const [inline]

Definition at line 20 of file wch.h.

References MsVal, and TSOut::Save().

{SOut.Save(MsVal); SOut.Save(MsVal);}

Here is the call graph for this function:

void TWCh::SaveTxt ( const PSOut SOut) const [inline]

Definition at line 39 of file wch.h.

References LsVal, MsVal, and TSOut::PutCh().

Referenced by TWChA::SaveTxt().

                                        {
    SOut->PutCh(MsVal); SOut->PutCh(LsVal);}

Here is the call graph for this function:

Here is the caller graph for this function:


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.

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.

Referenced by GetCh(), GetMemUsed(), GetSecHashCd(), LoadTxt(), operator<(), operator=(), operator==(), Save(), SaveTxt(), and TWCh().

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.

Referenced by TWChA::LoadTxt(), and TWChA::SaveTxt().

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: