casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Static Public Member Functions | Private Member Functions
casa::CanonicalConversion Class Reference

LDOUBLE is 8 bytes on SUN, but 16 bytes canonical. More...

#include <CanonicalConversion.h>

List of all members.

Static Public Member Functions

static unsigned int toLocal (char &to, const void *from)
 Convert one value from canonical format to local format.
static unsigned int toLocal (unsigned char &to, const void *from)
static unsigned int toLocal (short &to, const void *from)
static unsigned int toLocal (unsigned short &to, const void *from)
static unsigned int toLocal (int &to, const void *from)
static unsigned int toLocal (unsigned int &to, const void *from)
static unsigned int toLocal (Int64 &to, const void *from)
static unsigned int toLocal (uInt64 &to, const void *from)
static unsigned int toLocal (float &to, const void *from)
static unsigned int toLocal (double &to, const void *from)
static unsigned int fromLocal (void *to, const char &from)
 Convert one value from local format to canonical format.
static unsigned int fromLocal (void *to, const unsigned char &from)
static unsigned int fromLocal (void *to, const short &from)
static unsigned int fromLocal (void *to, const unsigned short &from)
static unsigned int fromLocal (void *to, const int &from)
static unsigned int fromLocal (void *to, const unsigned int &from)
static unsigned int fromLocal (void *to, const Int64 &from)
static unsigned int fromLocal (void *to, const uInt64 &from)
static unsigned int fromLocal (void *to, const float &from)
static unsigned int fromLocal (void *to, const double &from)
static unsigned int toLocal (char *to, const void *from, unsigned int nr)
 Convert nr values from canonical format to local format.
static unsigned int toLocal (unsigned char *to, const void *from, unsigned int nr)
static unsigned int toLocal (short *to, const void *from, unsigned int nr)
static unsigned int toLocal (unsigned short *to, const void *from, unsigned int nr)
static unsigned int toLocal (int *to, const void *from, unsigned int nr)
static unsigned int toLocal (unsigned int *to, const void *from, unsigned int nr)
static unsigned int toLocal (Int64 *to, const void *from, unsigned int nr)
static unsigned int toLocal (uInt64 *to, const void *from, unsigned int nr)
static unsigned int toLocal (float *to, const void *from, unsigned int nr)
static unsigned int toLocal (double *to, const void *from, unsigned int nr)
static unsigned int fromLocal (void *to, const char *from, unsigned int nr)
 Convert nr values from local format to canonical format.
static unsigned int fromLocal (void *to, const unsigned char *from, unsigned int nr)
static unsigned int fromLocal (void *to, const short *from, unsigned int nr)
static unsigned int fromLocal (void *to, const unsigned short *from, unsigned int nr)
static unsigned int fromLocal (void *to, const int *from, unsigned int nr)
static unsigned int fromLocal (void *to, const unsigned int *from, unsigned int nr)
static unsigned int fromLocal (void *to, const Int64 *from, unsigned int nr)
static unsigned int fromLocal (void *to, const uInt64 *from, unsigned int nr)
static unsigned int fromLocal (void *to, const float *from, unsigned int nr)
static unsigned int fromLocal (void *to, const double *from, unsigned int nr)
static unsigned int toLocalChar (void *to, const void *from, unsigned int nr)
 Convert nr values from canonical format to local format.
static unsigned int toLocalUChar (void *to, const void *from, unsigned int nr)
static unsigned int toLocalShort (void *to, const void *from, unsigned int nr)
static unsigned int toLocalUShort (void *to, const void *from, unsigned int nr)
static unsigned int toLocalInt (void *to, const void *from, unsigned int nr)
static unsigned int toLocalUInt (void *to, const void *from, unsigned int nr)
static unsigned int toLocalInt64 (void *to, const void *from, unsigned int nr)
static unsigned int toLocalUInt64 (void *to, const void *from, unsigned int nr)
static unsigned int toLocalFloat (void *to, const void *from, unsigned int nr)
static unsigned int toLocalDouble (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalChar (void *to, const void *from, unsigned int nr)
 Convert nr values from local format to canonical format.
static unsigned int fromLocalUChar (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalShort (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalUShort (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalInt (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalUInt (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalInt64 (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalUInt64 (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalFloat (void *to, const void *from, unsigned int nr)
static unsigned int fromLocalDouble (void *to, const void *from, unsigned int nr)
static void * byteToLocalChar (void *to, const void *from, unsigned int nrbytes)
 Convert values from canonical format to local format.
static void * byteToLocalUChar (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalShort (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalUShort (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalInt (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalUInt (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalInt64 (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalUInt64 (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalFloat (void *to, const void *from, unsigned int nrbytes)
static void * byteToLocalDouble (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalChar (void *to, const void *from, unsigned int nrbytes)
 Convert values from local format to canonical format.
static void * byteFromLocalUChar (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalShort (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalUShort (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalInt (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalUInt (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalInt64 (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalUInt64 (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalFloat (void *to, const void *from, unsigned int nrbytes)
static void * byteFromLocalDouble (void *to, const void *from, unsigned int nrbytes)
static Conversion::ValueFunctiongetToLocal (const char *)
 Get the value conversion function for the given type.
static Conversion::ValueFunctiongetToLocal (const unsigned char *)
static Conversion::ValueFunctiongetToLocal (const short *)
static Conversion::ValueFunctiongetToLocal (const unsigned short *)
static Conversion::ValueFunctiongetToLocal (const int *)
static Conversion::ValueFunctiongetToLocal (const unsigned int *)
static Conversion::ValueFunctiongetToLocal (const Int64 *)
static Conversion::ValueFunctiongetToLocal (const uInt64 *)
static Conversion::ValueFunctiongetToLocal (const float *)
static Conversion::ValueFunctiongetToLocal (const double *)
static Conversion::ValueFunctiongetFromLocal (const char *)
static Conversion::ValueFunctiongetFromLocal (const unsigned char *)
static Conversion::ValueFunctiongetFromLocal (const short *)
static Conversion::ValueFunctiongetFromLocal (const unsigned short *)
static Conversion::ValueFunctiongetFromLocal (const int *)
static Conversion::ValueFunctiongetFromLocal (const unsigned int *)
static Conversion::ValueFunctiongetFromLocal (const Int64 *)
static Conversion::ValueFunctiongetFromLocal (const uInt64 *)
static Conversion::ValueFunctiongetFromLocal (const float *)
static Conversion::ValueFunctiongetFromLocal (const double *)
static Conversion::ByteFunctiongetByteToLocal (const char *)
 Get the byte conversion function for the given type.
static Conversion::ByteFunctiongetByteToLocal (const unsigned char *)
static Conversion::ByteFunctiongetByteToLocal (const short *)
static Conversion::ByteFunctiongetByteToLocal (const unsigned short *)
static Conversion::ByteFunctiongetByteToLocal (const int *)
static Conversion::ByteFunctiongetByteToLocal (const unsigned int *)
static Conversion::ByteFunctiongetByteToLocal (const Int64 *)
static Conversion::ByteFunctiongetByteToLocal (const uInt64 *)
static Conversion::ByteFunctiongetByteToLocal (const float *)
static Conversion::ByteFunctiongetByteToLocal (const double *)
static Conversion::ByteFunctiongetByteFromLocal (const char *)
static Conversion::ByteFunctiongetByteFromLocal (const unsigned char *)
static Conversion::ByteFunctiongetByteFromLocal (const short *)
static Conversion::ByteFunctiongetByteFromLocal (const unsigned short *)
static Conversion::ByteFunctiongetByteFromLocal (const int *)
static Conversion::ByteFunctiongetByteFromLocal (const unsigned int *)
static Conversion::ByteFunctiongetByteFromLocal (const Int64 *)
static Conversion::ByteFunctiongetByteFromLocal (const uInt64 *)
static Conversion::ByteFunctiongetByteFromLocal (const float *)
static Conversion::ByteFunctiongetByteFromLocal (const double *)
static unsigned int canonicalSize (const char *)
 Return the canonical length for the various data types.
static unsigned int canonicalSize (const unsigned char *)
static unsigned int canonicalSize (const short *)
static unsigned int canonicalSize (const unsigned short *)
static unsigned int canonicalSize (const int *)
static unsigned int canonicalSize (const unsigned int *)
static unsigned int canonicalSize (const Int64 *)
static unsigned int canonicalSize (const uInt64 *)
static unsigned int canonicalSize (const float *)
static unsigned int canonicalSize (const double *)
static void reverse2 (void *to, const void *from)
 Reverse 2 bytes.
static void reverse4 (void *to, const void *from)
 Reverse 4 bytes.
static void reverse8 (void *to, const void *from)
 Reverse 8 bytes.
static void move2 (void *to, const void *from)
 Move 2 bytes.
static void move4 (void *to, const void *from)
 Move 4 bytes.
static void move8 (void *to, const void *from)
 Move 8 bytes.

Private Member Functions

 CanonicalConversion ()
 This class should not be constructed (so declare the constructor private).

Detailed Description

LDOUBLE is 8 bytes on SUN, but 16 bytes canonical.

A class with static functions to convert canonical format

Intended use:

Public interface

Review Status

Reviewed By:
Friso Olnon
Date Reviewed:
1996/11/06
Test programs:
tCanonicalConversion

Synopsis

This class consists of several static functions to convert data from local (=native) format to a canonical format. The canonical length of each data type is:
- Bool: 1 bit
- char: 1 byte
- short: 2 bytes
- int: 4 bytes
- Int64: 8 bytes
- float: 4 bytes
- double: 8 bytes
The canonical format is big-endian IEEE format, so on many machines the conversion is only a copy operation. On Alpha- or Intel-based machines, however, it involves a byte swap to convert from little endian to big endian.

The class also contains conversion functions making it possible to specify the number of bytes (in local format) instead of the number of values. These functions are included to make it possible to have the same signature as memcpy.

The current implementation of this class works on big- and little-endian machines using IEEE format. When using on other machines (e.g. VAX) the toLocal and fromLocal functions have to be changed.

Note that no functions are provided to handle Bools. Instead class Conversion provides functions to convert Bools to/from bits.

Example

    void someFunction (const uInt* data, uInt nrval)
    {
        char* buffer = new char[nrval*CanonicalConversion::canonicalSize(data)];
        CanonicalConversion::fromLocal (buffer, data, nrval);
        ...\.
        delete [] buffer;
    }

Motivation

AIPS++ data will be stored in a canonical format. To read these data conversion functions are needed. However, these functions do not use any other AIPS++ classes, so they can easily be used in any other software system.

To Do

Definition at line 160 of file CanonicalConversion.h.


Constructor & Destructor Documentation

This class should not be constructed (so declare the constructor private).


Member Function Documentation

static void* casa::CanonicalConversion::byteFromLocalChar ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]

Convert values from local format to canonical format.

The from and to buffer should not overlap. The number of values involved is determined from the argument nrbytes, which gives the number of bytes in local format. The signature of this function is the same as memcpy, so that memcpy can directly be used if no conversion is needed.

static void* casa::CanonicalConversion::byteFromLocalDouble ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalFloat ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalInt ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalInt64 ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalShort ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalUChar ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalUInt ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalUInt64 ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteFromLocalUShort ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalChar ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]

Convert values from canonical format to local format.

The from and to buffer should not overlap. The number of values involved is determined from the argument nrbytes, which gives the number of bytes in local format. The signature of this function is the same as memcpy, so that memcpy can directly be used if no conversion is needed.

static void* casa::CanonicalConversion::byteToLocalDouble ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalFloat ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalInt ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalInt64 ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalShort ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalUChar ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalUInt ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalUInt64 ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
static void* casa::CanonicalConversion::byteToLocalUShort ( void *  to,
const void *  from,
unsigned int  nrbytes 
) [static]
unsigned int casa::CanonicalConversion::canonicalSize ( const char *  ) [inline, static]

Return the canonical length for the various data types.

Definition at line 948 of file CanonicalConversion.h.

References SIZE_CAN_CHAR.

unsigned int casa::CanonicalConversion::canonicalSize ( const unsigned char *  ) [inline, static]

Definition at line 950 of file CanonicalConversion.h.

References SIZE_CAN_UCHAR.

unsigned int casa::CanonicalConversion::canonicalSize ( const short *  ) [inline, static]

Definition at line 952 of file CanonicalConversion.h.

References SIZE_CAN_SHORT.

unsigned int casa::CanonicalConversion::canonicalSize ( const unsigned short *  ) [inline, static]

Definition at line 954 of file CanonicalConversion.h.

References SIZE_CAN_USHORT.

unsigned int casa::CanonicalConversion::canonicalSize ( const int *  ) [inline, static]

Definition at line 956 of file CanonicalConversion.h.

References SIZE_CAN_INT.

unsigned int casa::CanonicalConversion::canonicalSize ( const unsigned int *  ) [inline, static]

Definition at line 958 of file CanonicalConversion.h.

References SIZE_CAN_UINT.

unsigned int casa::CanonicalConversion::canonicalSize ( const Int64 ) [inline, static]

Definition at line 960 of file CanonicalConversion.h.

References SIZE_CAN_INT64.

unsigned int casa::CanonicalConversion::canonicalSize ( const uInt64 ) [inline, static]

Definition at line 962 of file CanonicalConversion.h.

References SIZE_CAN_UINT64.

unsigned int casa::CanonicalConversion::canonicalSize ( const float *  ) [inline, static]

Definition at line 964 of file CanonicalConversion.h.

References SIZE_CAN_FLOAT.

unsigned int casa::CanonicalConversion::canonicalSize ( const double *  ) [inline, static]

Definition at line 966 of file CanonicalConversion.h.

References SIZE_CAN_DOUBLE.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const char &  from 
) [inline, static]

Convert one value from local format to canonical format.

The from and to buffer should not overlap.

Definition at line 620 of file CanonicalConversion.h.

References SIZE_CAN_CHAR.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const unsigned char &  from 
) [inline, static]

Definition at line 626 of file CanonicalConversion.h.

References SIZE_CAN_UCHAR.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const short &  from 
) [inline, static]

Definition at line 633 of file CanonicalConversion.h.

References move2(), reverse2(), and SIZE_CAN_SHORT.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const unsigned short &  from 
) [inline, static]

Definition at line 644 of file CanonicalConversion.h.

References move2(), reverse2(), and SIZE_CAN_USHORT.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const int &  from 
) [inline, static]

Definition at line 655 of file CanonicalConversion.h.

References move4(), reverse4(), and SIZE_CAN_INT.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const unsigned int &  from 
) [inline, static]

Definition at line 666 of file CanonicalConversion.h.

References move4(), reverse4(), and SIZE_CAN_UINT.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const Int64 from 
) [inline, static]

Definition at line 677 of file CanonicalConversion.h.

References move8(), reverse8(), and SIZE_CAN_INT64.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const uInt64 from 
) [inline, static]

Definition at line 688 of file CanonicalConversion.h.

References move8(), reverse8(), and SIZE_CAN_UINT64.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const float &  from 
) [inline, static]

Definition at line 699 of file CanonicalConversion.h.

References move4(), reverse4(), and SIZE_CAN_FLOAT.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const double &  from 
) [inline, static]

Definition at line 710 of file CanonicalConversion.h.

References move8(), reverse8(), and SIZE_CAN_FLOAT.

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const char *  from,
unsigned int  nr 
) [inline, static]

Convert nr values from local format to canonical format.

The from and to buffer should not overlap.

Definition at line 783 of file CanonicalConversion.h.

References fromLocalChar().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const unsigned char *  from,
unsigned int  nr 
) [inline, static]

Definition at line 789 of file CanonicalConversion.h.

References fromLocalUChar().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const short *  from,
unsigned int  nr 
) [inline, static]

Definition at line 795 of file CanonicalConversion.h.

References fromLocalShort().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const unsigned short *  from,
unsigned int  nr 
) [inline, static]

Definition at line 801 of file CanonicalConversion.h.

References fromLocalUShort().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const int *  from,
unsigned int  nr 
) [inline, static]

Definition at line 807 of file CanonicalConversion.h.

References fromLocalInt().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const unsigned int *  from,
unsigned int  nr 
) [inline, static]

Definition at line 813 of file CanonicalConversion.h.

References fromLocalUInt().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const Int64 from,
unsigned int  nr 
) [inline, static]

Definition at line 819 of file CanonicalConversion.h.

References fromLocalInt64().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const uInt64 from,
unsigned int  nr 
) [inline, static]

Definition at line 825 of file CanonicalConversion.h.

References fromLocalUInt64().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const float *  from,
unsigned int  nr 
) [inline, static]

Definition at line 831 of file CanonicalConversion.h.

References fromLocalFloat().

unsigned int casa::CanonicalConversion::fromLocal ( void *  to,
const double *  from,
unsigned int  nr 
) [inline, static]

Definition at line 837 of file CanonicalConversion.h.

References fromLocalDouble().

static unsigned int casa::CanonicalConversion::fromLocalChar ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Convert nr values from local format to canonical format.

The from and to buffer should not overlap.

Referenced by casa::ModcompConversion::fromLocal(), and fromLocal().

static unsigned int casa::CanonicalConversion::fromLocalDouble ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by fromLocal().

static unsigned int casa::CanonicalConversion::fromLocalFloat ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by fromLocal().

static unsigned int casa::CanonicalConversion::fromLocalInt ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::fromLocalInt64 ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by fromLocal().

static unsigned int casa::CanonicalConversion::fromLocalShort ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::fromLocalUChar ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::fromLocalUInt ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::fromLocalUInt64 ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by fromLocal().

static unsigned int casa::CanonicalConversion::fromLocalUShort ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static Conversion::ByteFunction* casa::CanonicalConversion::getByteFromLocal ( const unsigned char *  ) [static]
static Conversion::ByteFunction* casa::CanonicalConversion::getByteFromLocal ( const unsigned short *  ) [static]
static Conversion::ByteFunction* casa::CanonicalConversion::getByteFromLocal ( const unsigned int *  ) [static]

Get the byte conversion function for the given type.

The function memcpy is returned when a conversion is not needed.

static Conversion::ByteFunction* casa::CanonicalConversion::getByteToLocal ( const unsigned char *  ) [static]
static Conversion::ByteFunction* casa::CanonicalConversion::getByteToLocal ( const unsigned short *  ) [static]
static Conversion::ByteFunction* casa::CanonicalConversion::getByteToLocal ( const unsigned int *  ) [static]

Definition at line 897 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getFromLocal ( const unsigned char *  ) [inline, static]

Definition at line 902 of file CanonicalConversion.h.

Definition at line 907 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getFromLocal ( const unsigned short *  ) [inline, static]

Definition at line 912 of file CanonicalConversion.h.

Definition at line 917 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getFromLocal ( const unsigned int *  ) [inline, static]

Definition at line 922 of file CanonicalConversion.h.

Definition at line 927 of file CanonicalConversion.h.

Definition at line 932 of file CanonicalConversion.h.

Definition at line 937 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getFromLocal ( const double *  ) [inline, static]

Definition at line 942 of file CanonicalConversion.h.

Get the value conversion function for the given type.

Definition at line 846 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getToLocal ( const unsigned char *  ) [inline, static]

Definition at line 851 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getToLocal ( const short *  ) [inline, static]

Definition at line 856 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getToLocal ( const unsigned short *  ) [inline, static]

Definition at line 861 of file CanonicalConversion.h.

Definition at line 866 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getToLocal ( const unsigned int *  ) [inline, static]

Definition at line 871 of file CanonicalConversion.h.

Definition at line 876 of file CanonicalConversion.h.

Definition at line 881 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getToLocal ( const float *  ) [inline, static]

Definition at line 886 of file CanonicalConversion.h.

Conversion::ValueFunction * casa::CanonicalConversion::getToLocal ( const double *  ) [inline, static]

Definition at line 891 of file CanonicalConversion.h.

void casa::CanonicalConversion::move2 ( void *  to,
const void *  from 
) [inline, static]
void casa::CanonicalConversion::move4 ( void *  to,
const void *  from 
) [inline, static]
void casa::CanonicalConversion::move8 ( void *  to,
const void *  from 
) [inline, static]
void casa::CanonicalConversion::reverse2 ( void *  to,
const void *  from 
) [inline, static]
void casa::CanonicalConversion::reverse4 ( void *  to,
const void *  from 
) [inline, static]
void casa::CanonicalConversion::reverse8 ( void *  to,
const void *  from 
) [inline, static]
unsigned int casa::CanonicalConversion::toLocal ( char &  to,
const void *  from 
) [inline, static]

Convert one value from canonical format to local format.

The from and to buffer should not overlap.

Definition at line 494 of file CanonicalConversion.h.

References SIZE_CAN_CHAR.

unsigned int casa::CanonicalConversion::toLocal ( unsigned char &  to,
const void *  from 
) [inline, static]

Definition at line 500 of file CanonicalConversion.h.

References SIZE_CAN_UCHAR.

unsigned int casa::CanonicalConversion::toLocal ( short &  to,
const void *  from 
) [inline, static]

Definition at line 507 of file CanonicalConversion.h.

References move2(), reverse2(), and SIZE_CAN_SHORT.

unsigned int casa::CanonicalConversion::toLocal ( unsigned short &  to,
const void *  from 
) [inline, static]

Definition at line 524 of file CanonicalConversion.h.

References move2(), reverse2(), and SIZE_CAN_USHORT.

unsigned int casa::CanonicalConversion::toLocal ( int &  to,
const void *  from 
) [inline, static]

Definition at line 538 of file CanonicalConversion.h.

References move4(), reverse4(), and SIZE_CAN_INT.

unsigned int casa::CanonicalConversion::toLocal ( unsigned int &  to,
const void *  from 
) [inline, static]

Definition at line 555 of file CanonicalConversion.h.

References move4(), reverse4(), and SIZE_CAN_UINT.

unsigned int casa::CanonicalConversion::toLocal ( Int64 to,
const void *  from 
) [inline, static]

Definition at line 569 of file CanonicalConversion.h.

References move8(), reverse8(), and SIZE_CAN_INT64.

unsigned int casa::CanonicalConversion::toLocal ( uInt64 to,
const void *  from 
) [inline, static]

Definition at line 586 of file CanonicalConversion.h.

References move8(), reverse8(), and SIZE_CAN_UINT64.

unsigned int casa::CanonicalConversion::toLocal ( float &  to,
const void *  from 
) [inline, static]

Definition at line 599 of file CanonicalConversion.h.

References move4(), reverse4(), and SIZE_CAN_FLOAT.

unsigned int casa::CanonicalConversion::toLocal ( double &  to,
const void *  from 
) [inline, static]

Definition at line 609 of file CanonicalConversion.h.

References move8(), reverse8(), and SIZE_CAN_DOUBLE.

unsigned int casa::CanonicalConversion::toLocal ( char *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Convert nr values from canonical format to local format.

The from and to buffer should not overlap.

Definition at line 722 of file CanonicalConversion.h.

References toLocalChar().

unsigned int casa::CanonicalConversion::toLocal ( unsigned char *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 728 of file CanonicalConversion.h.

References toLocalUChar().

unsigned int casa::CanonicalConversion::toLocal ( short *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 734 of file CanonicalConversion.h.

References toLocalShort().

unsigned int casa::CanonicalConversion::toLocal ( unsigned short *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 740 of file CanonicalConversion.h.

References toLocalUShort().

unsigned int casa::CanonicalConversion::toLocal ( int *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 746 of file CanonicalConversion.h.

References toLocalInt().

unsigned int casa::CanonicalConversion::toLocal ( unsigned int *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 752 of file CanonicalConversion.h.

References toLocalUInt().

unsigned int casa::CanonicalConversion::toLocal ( Int64 to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 758 of file CanonicalConversion.h.

References toLocalInt64().

unsigned int casa::CanonicalConversion::toLocal ( uInt64 to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 764 of file CanonicalConversion.h.

References toLocalUInt64().

unsigned int casa::CanonicalConversion::toLocal ( float *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 770 of file CanonicalConversion.h.

References toLocalFloat().

unsigned int casa::CanonicalConversion::toLocal ( double *  to,
const void *  from,
unsigned int  nr 
) [inline, static]

Definition at line 776 of file CanonicalConversion.h.

References toLocalDouble().

static unsigned int casa::CanonicalConversion::toLocalChar ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Convert nr values from canonical format to local format.

The from and to buffer should not overlap.

Referenced by casa::ModcompConversion::toLocal(), and toLocal().

static unsigned int casa::CanonicalConversion::toLocalDouble ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by toLocal().

static unsigned int casa::CanonicalConversion::toLocalFloat ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by toLocal().

static unsigned int casa::CanonicalConversion::toLocalInt ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::toLocalInt64 ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by toLocal().

static unsigned int casa::CanonicalConversion::toLocalShort ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::toLocalUChar ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::toLocalUInt ( void *  to,
const void *  from,
unsigned int  nr 
) [static]
static unsigned int casa::CanonicalConversion::toLocalUInt64 ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

Referenced by toLocal().

static unsigned int casa::CanonicalConversion::toLocalUShort ( void *  to,
const void *  from,
unsigned int  nr 
) [static]

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