Loading...
Searching...
No Matches
CanonicalConversion.h File Reference
`#include <casacore/casa/aips.h>`
`#include <casacore/casa/OS/Conversion.h>`
`#include <cstring>`

Go to the source code of this file.

## Classes

class | casacore::CanonicalConversion
| LDOUBLE is 8 bytes on SUN, but 16 bytes canonical. More...

## Namespaces

namespace | casacore
| this file contains all the compiler specific defines

## Macros

#define | SIZE_CAN_CHAR
| Define the canonical sizes of the built-in data types.
#define | SIZE_CAN_UCHAR
#define | SIZE_CAN_SHORT
#define | SIZE_CAN_USHORT
#define | SIZE_CAN_INT
#define | SIZE_CAN_UINT
#define | SIZE_CAN_INT64
#define | SIZE_CAN_UINT64
#define | SIZE_CAN_FLOAT
#define | SIZE_CAN_DOUBLE
#define | CONVERT_CAN_CHAR
| Define for each data format if a conversion is needed from the local format to the canonical format (or vice-versa).
#define | CONVERT_CAN_UCHAR
#define | CONVERT_CAN_SHORT
| Conversion is not needed for IEEE data.
#define | CONVERT_CAN_USHORT
#define | CONVERT_CAN_INT
#define | CONVERT_CAN_UINT
#define | CONVERT_CAN_INT64
#define | CONVERT_CAN_UINT64
#define | CONVERT_CAN_FLOAT
#define | CONVERT_CAN_DOUBLE

## Macro Definition Documentation

## CONVERT_CAN_CHAR

#define CONVERT_CAN_CHAR

Define for each data format if a conversion is needed from the local format to the canonical format (or vice-versa).

This allows for optimizations in, for example, AipsIO. The canonical format is ASCII for strings, IEEE for floating point and 2-complement for integers (all most significant bit first) with the lengths as shown above. The function checkConvert() can be used to check if the flags are set correctly.

Conversion is needed for little endian architectures (like DEC and Intel), because the bytes have to be swapped (thus not for data with length 1).

Definition at line 65 of file CanonicalConversion.h.

## CONVERT_CAN_DOUBLE

#define CONVERT_CAN_DOUBLE

Definition at line 89 of file CanonicalConversion.h.

## CONVERT_CAN_FLOAT

#define CONVERT_CAN_FLOAT

Definition at line 88 of file CanonicalConversion.h.

## CONVERT_CAN_INT

#define CONVERT_CAN_INT

Definition at line 84 of file CanonicalConversion.h.

## CONVERT_CAN_INT64

#define CONVERT_CAN_INT64

Definition at line 86 of file CanonicalConversion.h.

## CONVERT_CAN_SHORT

#define CONVERT_CAN_SHORT

Conversion is not needed for IEEE data.

Change the definitions below if new architectures are being used.

Definition at line 82 of file CanonicalConversion.h.

## CONVERT_CAN_UCHAR

#define CONVERT_CAN_UCHAR

Definition at line 66 of file CanonicalConversion.h.

## CONVERT_CAN_UINT

#define CONVERT_CAN_UINT

Definition at line 85 of file CanonicalConversion.h.

## CONVERT_CAN_UINT64

#define CONVERT_CAN_UINT64

Definition at line 87 of file CanonicalConversion.h.

## CONVERT_CAN_USHORT

#define CONVERT_CAN_USHORT

Definition at line 83 of file CanonicalConversion.h.

## SIZE_CAN_CHAR

#define SIZE_CAN_CHAR

Define the canonical sizes of the built-in data types.

These are the same for all machine architectures. Also define the maximum size.

Definition at line 41 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_DOUBLE

#define SIZE_CAN_DOUBLE

Definition at line 50 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_FLOAT

#define SIZE_CAN_FLOAT

Definition at line 49 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_INT

#define SIZE_CAN_INT

Definition at line 45 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_INT64

#define SIZE_CAN_INT64

Definition at line 47 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_SHORT

#define SIZE_CAN_SHORT

Definition at line 43 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_UCHAR

#define SIZE_CAN_UCHAR

Definition at line 42 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_UINT

#define SIZE_CAN_UINT

Definition at line 46 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_UINT64

#define SIZE_CAN_UINT64

Definition at line 48 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().

## SIZE_CAN_USHORT

#define SIZE_CAN_USHORT

Definition at line 44 of file CanonicalConversion.h.

Referenced by casacore::CanonicalConversion::canonicalSize(), casacore::CanonicalConversion::fromLocal(), and casacore::CanonicalConversion::toLocal().