31#include <casacore/casa/aips.h>
32#include <casacore/casa/BasicSL/Constants.h>
33#include <casacore/casa/stdmap.h>
34#include <casacore/casa/BasicSL/String.h>
35#include <casacore/casa/Quanta/UnitDim.h>
36#include <casacore/casa/Quanta/UnitVal.h>
37#include <casacore/casa/Quanta/UnitName.h>
318 static const map<String, UnitName> &
giveDef();
319 static const map<String, UnitName> &
giveSI();
String: the storage and methods of handling collections of characters.
Define a struct containing the static data members.
map< String, UnitName > mapPref
Decimal prefix list.
Bool doneFITS
FITS unit list inclusion.
map< String, UnitName > mapDef
Defining SI unit list.
map< String, UnitName > mapCust
Customary list.
map< String, UnitName > mapUser
User defined unit list.
map< String, UnitName > mapSI
SI unit list.
static void initUMSI1(UMaps &)
static void initUMSI2(UMaps &)
static void listCache(ostream &os)
List all units in cache.
static const map< String, UnitVal > & giveCache()
static const String & getStringFITS(uInt which)
Get the belonging unit to a FITS unit.
static void putUser(const String &s, const UnitVal &val)
Define a user defined standard unit.
UnitMap(const UnitMap &other)
Copy constructor (not implemented)
static const map< String, UnitName > & givePref()
Return the different maps.
static const map< String, UnitName > & giveCust()
static void list(ostream &os)
List some part of the standard unit lists on cout or stream
static void listSI(ostream &os)
List all SI units.
static void listPref(ostream &os)
List all prefixes.
static Unit toFITS(const Unit &un)
Translate to a FITS unit.
UnitMap & operator=(const UnitMap &other)
Copy assignment (not implemented)
static Bool getNameFITS(const UnitName *&name, uInt which)
Get the name of a FITS unit.
static Bool getPref(const String &s, UnitName &name, UMaps *maps=0)
Check if a unit name is known, and return its value if True
static Unit fromFITS(const Unit &un)
Translate a FITS unit to the proper units.
static void listUser(ostream &os)
List all user defined units.
static UMaps & getMaps()
Get the static UMaps struct.
UnitMap()
Default constructor of maps.
static const map< String, UnitName > & giveDef()
static Bool getCache(const String &s, UnitVal &val)
Get a cached definition.
static void initUMCust1(UMaps &)
static void initUMCust2(UMaps &)
static void putUser(const String &s, const UnitVal &val, const String &name)
static void listDef(ostream &os)
List all defining units.
static void clearFITS()
Clear FITS related units from user list.
static void removeUser(const String &name)
Remove a user unit.
static void putUser(const UnitName &name)
static void listCust(ostream &os)
List all customary units.
static Bool getUnit(const String &s, UnitName &name, UMaps *maps=0)
Get a standard unit definition (search order: User, Customary, SI)
static void initUMPrefix(UMaps &)
Bits and pieces of initUM() to get compilation speed improved.
static void putCache(const String &s, const UnitVal &val)
Save a definition of a full unit name in the cache (the cache will be cleared if getting too large (2...
static const map< String, UnitName > & giveSI()
static void clearCache()
Clear out the cache.
static void addFITS()
Define FITS related unit names.
static map< String, UnitVal > & getMapCache()
Get the static mapCache object.
static std::mutex fitsMutex
static void initUMCust3(UMaps &)
static const map< String, UnitName > & giveUser()
static void removeUser(const UnitName &name)
this file contains all the compiler specific defines
bool Bool
Define the standard types used by Casacore.
const uInt N_FITS
Number of FITS units recognised (change the FITSstring and FITSunit lists in the UnitMap....