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
TB4Def Class Reference

#include <bits.h>

Public Types

typedef uint TB4
 

Public Member Functions

 TB4Def ()
 
 ~TB4Def ()
 
TB4Defoperator= (const TB4Def &)
 

Static Public Member Functions

static int GetB4Bits (const TB4 &B4)
 
static uint GetP2 (const int &P2Exp)
 
static int GetL2 (const uint &Val)
 

Public Attributes

TB4B4P2T
 

Static Public Attributes

static const int B4Bits =32
 
static const int MxP2Exp =TB4Def::B4Bits-1
 
static const TB4 MxB4 =0xFFFFFFFF
 
static const TB4Def B4Def
 

Detailed Description

Definition at line 51 of file bits.h.

Member Typedef Documentation

typedef uint TB4Def::TB4

Definition at line 53 of file bits.h.

Constructor & Destructor Documentation

TB4Def::TB4Def ( )

Definition at line 77 of file bits.cpp.

77  {
78  B4P2T=new TB4[B4Bits+1]; B4P2T[0]=1;
79  for (int BitN=1; BitN<B4Bits; BitN++){B4P2T[BitN]=TB4(2*B4P2T[BitN-1]);}
80  B4P2T[B4Bits]=0;
81 }
uint TB4
Definition: bits.h:53
static const int B4Bits
Definition: bits.h:54
TB4 * B4P2T
Definition: bits.h:57
TB4Def::~TB4Def ( )
inline

Definition at line 60 of file bits.h.

60 {delete[] B4P2T;}
TB4 * B4P2T
Definition: bits.h:57

Member Function Documentation

int TB4Def::GetB4Bits ( const TB4 B4)
static

Definition at line 83 of file bits.cpp.

83  {
84  return
89 }
int * B1BitsT
Definition: bits.h:12
static const TB1 MxB1
Definition: bits.h:10
static const int B1Bits
Definition: bits.h:8
static const TB1Def B1Def
Definition: bits.h:24
int TB4Def::GetL2 ( const uint Val)
static

Definition at line 96 of file bits.cpp.

96  {
97  int L2=0;
98  while ((L2<TB4Def::MxP2Exp)&&(Val>=B4Def.B4P2T[L2])){L2++;}
99  return L2-1;
100 }
static const int MxP2Exp
Definition: bits.h:55
static const TB4Def B4Def
Definition: bits.h:68
TB4 * B4P2T
Definition: bits.h:57
uint TB4Def::GetP2 ( const int &  P2Exp)
static

Definition at line 91 of file bits.cpp.

91  {
92  IAssert((0<=P2Exp)&&(P2Exp<=TB4Def::MxP2Exp));
93  return B4Def.B4P2T[P2Exp];
94 }
#define IAssert(Cond)
Definition: bd.h:262
static const int MxP2Exp
Definition: bits.h:55
static const TB4Def B4Def
Definition: bits.h:68
TB4 * B4P2T
Definition: bits.h:57
TB4Def& TB4Def::operator= ( const TB4Def )
inline

Definition at line 62 of file bits.h.

62 {Fail; return *this;}
#define Fail
Definition: bd.h:238

Member Data Documentation

const int TB4Def::B4Bits =32
static

Definition at line 54 of file bits.h.

const TB4Def TB4Def::B4Def
static

Definition at line 68 of file bits.h.

TB4* TB4Def::B4P2T

Definition at line 57 of file bits.h.

const TB4Def::TB4 TB4Def::MxB4 =0xFFFFFFFF
static

Definition at line 56 of file bits.h.

const int TB4Def::MxP2Exp =TB4Def::B4Bits-1
static

Definition at line 55 of file bits.h.


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