Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

cps::IntConv Class Reference

#include <intconv.h>

Inherits cps::DataConversion.

List of all members.

Public Member Functions

enum INT_FORMAT setFileFormat (const char *desc)
enum INT_FORMAT setFileFormat (const enum INT_FORMAT dataFormat)
 IntConv ()
virtual ~IntConv ()
char * file2host (char *hbuf, const char *fdat, const int fdat_len) const
char * host2file (char *fbuf, const char *hdat, const int hdat_len) const
unsigned int checksum (char *data, const int data_len, const enum INT_FORMAT dataFormat) const
unsigned int posDepCsum (char *data, const int data_len, const int dimension, const QioArg &qio_arg, const int siteid, const int global_id, const enum INT_FORMAT dataFormat) const
int size (const enum INT_FORMAT datatype) const
int fileIntSize () const
int hostIntSize () const
bool big_endian (const enum INT_FORMAT datatype) const
int fileDataSize () const
int hostDataSize () const
unsigned int checksum (char *data, const int data_len) const
unsigned int posDepCsum (char *data, const int data_len, const int dimension, const QioArg &qio_arg, const int siteid, const int global_id) const

Static Public Member Functions

const char * name (const enum INT_FORMAT format)

Protected Member Functions

void byterevn (type32 w[], int n) const
void copy32 (type32 tgt[], type32 src[], int n) const
enum INT_FORMAT testHostFormat ()


Constructor & Destructor Documentation

cps::IntConv::IntConv  ) 
 

Definition at line 21 of file intconv.C.

References cps::INT_UNKNOWN, and testHostFormat().

cps::IntConv::~IntConv  )  [virtual]
 

Definition at line 27 of file intconv.C.


Member Function Documentation

bool cps::IntConv::big_endian const enum INT_FORMAT  datatype  )  const
 

Definition at line 255 of file intconv.C.

References cps::INT_32BIG, and cps::INT_32LITTLE.

Referenced by checksum(), file2host(), host2file(), and posDepCsum().

void cps::IntConv::byterevn type32  w[],
int  n
const [protected]
 

Definition at line 70 of file intconv.C.

References type32.

Referenced by checksum(), file2host(), host2file(), and posDepCsum().

unsigned int cps::IntConv::checksum char *  data,
const int  data_len
const [inline, virtual]
 

Implements cps::DataConversion.

Definition at line 61 of file intconv.h.

References cps::INT_AUTOMATIC.

unsigned int cps::IntConv::checksum char *  data,
const int  data_len,
const enum INT_FORMAT  dataFormat
const
 

Definition at line 161 of file intconv.C.

References big_endian(), byterevn(), cps::Verbose::Flow(), cps::INT_FORMAT, type32, and cps::VRB.

void cps::IntConv::copy32 type32  tgt[],
type32  src[],
int  n
const [protected]
 

Definition at line 96 of file intconv.C.

Referenced by file2host(), and host2file().

char * cps::IntConv::file2host char *  hbuf,
const char *  fdat,
const int  fdat_len
const [virtual]
 

Implements cps::DataConversion.

Definition at line 35 of file intconv.C.

References big_endian(), byterevn(), copy32(), size(), and type32.

int cps::IntConv::fileDataSize  )  const [inline, virtual]
 

Implements cps::DataConversion.

Definition at line 59 of file intconv.h.

int cps::IntConv::fileIntSize  )  const [inline]
 

Definition at line 54 of file intconv.h.

Referenced by cps::LatRngRead::read(), and cps::LatRngWrite::write().

char * cps::IntConv::host2file char *  fbuf,
const char *  hdat,
const int  hdat_len
const [virtual]
 

Implements cps::DataConversion.

Definition at line 52 of file intconv.C.

References big_endian(), byterevn(), copy32(), size(), and type32.

int cps::IntConv::hostDataSize  )  const [inline, virtual]
 

Implements cps::DataConversion.

Definition at line 60 of file intconv.h.

int cps::IntConv::hostIntSize  )  const [inline]
 

Definition at line 55 of file intconv.h.

const char * cps::IntConv::name const enum INT_FORMAT  format  )  [static]
 

Definition at line 31 of file intconv.C.

References cps::INT_FORMAT_NAME.

unsigned int cps::IntConv::posDepCsum char *  data,
const int  data_len,
const int  dimension,
const QioArg qio_arg,
const int  siteid,
const int  global_id
const [inline, virtual]
 

Implements cps::DataConversion.

Definition at line 64 of file intconv.h.

References cps::INT_AUTOMATIC.

unsigned int cps::IntConv::posDepCsum char *  data,
const int  data_len,
const int  dimension,
const QioArg qio_arg,
const int  siteid,
const int  global_id,
const enum INT_FORMAT  dataFormat
const
 

Definition at line 192 of file intconv.C.

References big_endian(), byterevn(), cps::QioArg::Coor(), cps::Verbose::Flow(), cps::INT_FORMAT, cps::QioArg::Nodes(), cps::QioArg::NodeSites(), type32, and cps::VRB.

enum INT_FORMAT cps::IntConv::setFileFormat const enum INT_FORMAT  dataFormat  ) 
 

Definition at line 130 of file intconv.C.

References cps::Verbose::Flow(), cps::INT_FORMAT, and cps::VRB.

enum INT_FORMAT cps::IntConv::setFileFormat const char *  desc  ) 
 

Definition at line 142 of file intconv.C.

References cps::Verbose::Flow(), cps::INT_FORMAT, cps::INT_FORMAT_NAME, and cps::VRB.

Referenced by cps::LatRngRead::read(), cps::LatRngHeader::read(), and cps::LatRngWrite::write().

int cps::IntConv::size const enum INT_FORMAT  datatype  )  const
 

Definition at line 245 of file intconv.C.

References cps::INT_32BIG, and cps::INT_32LITTLE.

Referenced by file2host(), and host2file().

enum INT_FORMAT cps::IntConv::testHostFormat  )  [protected]
 

Definition at line 102 of file intconv.C.

References cps::ERR, cps::INT_FORMAT, and cps::Error::NotImplemented().

Referenced by IntConv().


The documentation for this class was generated from the following files:
Generated on Sat Oct 10 14:12:07 2009 for Columbia Physics System by  doxygen 1.3.9.1