source: trunk/gsdl/packages/isis-gdl/IsisTypes.h@ 7138

Last change on this file since 7138 was 7100, checked in by davidb, 20 years ago

Tweak to IsisTypes.h so double_t in global namespace is same
as Isis namespace (it isn't redefined if already in math.h)

`CVS: ----------------------------------------------------------------------

  • Property svn:keywords set to Author Date Id Revision
File size: 3.3 KB
Line 
1/**********************************************************************
2 *
3 * IsisTypes.h
4 * Copyright (C) 2003 UNESCO
5 *
6 * A component of the Greenstone digital library software
7 * from the New Zealand Digital Library Project at the
8 * University of Waikato, New Zealand.
9 *
10 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
19 *
20 * You should have received a copy of the GNU General Public License
21 * along with this program; if not, write to the Free Software
22 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
23 *
24 *********************************************************************/
25
26///////////////////////////////////////////////////////////////////////////////
27// isisType.h
28
29
30#ifndef __ISIS_TYPE_H__
31#define __ISIS_TYPE_H__
32
33#include "DLLCode.h"
34
35namespace isis
36{
37
38
39// ----------------------------------------
40// Type definitions common to all platforms
41// ----------------------------------------
42typedef char int8_t; // 8-bit signed value
43typedef unsigned char uint8_t; // 8-bit unsigned value
44typedef int int32_t; // Word size (4 bytes)
45typedef unsigned int uint32_t; // Unsigned word size (4 bytes)
46typedef long long32_t; // Long word (4 bytes)
47typedef unsigned long ulong32_t; // Unsigned long word (4 bytes)
48typedef short int16_t; // short word (2 bytes)
49typedef unsigned short uint16_t; // Unsigned short word (2 bytes)
50#ifndef __USE_ISOC99 // gnu lic math.h has a double_t
51typedef double double_t; // Double precision floating point (8 bytes)
52#endif
53
54
55// --------------------------------------------------------------
56// Platform/compiler specific INT64 types
57// --------------------------------------------------------------
58#if defined (__64_BIT_FILE_SYSTEM__)
59#include "TYPES64.H"
60#endif
61} // namespace isis
62
63namespace isis
64{
65 typedef isis::int16_t db_t;
66 typedef isis::int16_t server_t;
67 typedef isis::int16_t IsisClientId;
68 typedef isis::uint32_t mfn_t;
69}
70// typedef char int8_t; // 8-bit signed value
71typedef unsigned char uint8_t; // 8-bit unsigned value
72typedef int int32_t; // Word size (4 bytes)
73typedef unsigned int uint32_t; // Unsigned word size (4 bytes)
74typedef long long32_t; // Long word (4 bytes)
75typedef unsigned long ulong32_t; // Unsigned long word (4 bytes)
76typedef short int16_t; // short word (2 bytes)
77typedef unsigned short uint16_t; // Unsigned short word (2 bytes)
78#ifndef __USE_ISOC99 // gnu lic math.h has a double_t
79typedef double double_t; // Double precision floating point (8 bytes) // ****
80#endif
81
82typedef uint32_t xrf_page_no_t;
83
84typedef uint32_t mst_page_no_t;
85typedef uint16_t mst_offset_t;
86typedef uint32_t mfn_t;
87typedef uint32_t mfrl_t;
88
89typedef isis::uint32_t file_size_t;
90
91
92#endif // __ISIS_TYPE_H__
93
94
95
Note: See TracBrowser for help on using the repository browser.