#ifndef __DB_D_TYPES_H__
#define __DB_D_TYPES_H__

// Diamond base type definitions.

// Will break on alpha machines.

#if 0
// These are done in defs.h via autoconf
#ifndef __BORLANDC__
//
// I think borland already has these built in
//
typedef long int32;
typedef short int16;
#endif
#endif

#include <diamond/dbstr.h>

typedef double moneyType;
typedef int32 dateType;
typedef int32 uniqueType;

// type enumeration.

enum DIA_FieldType {D_LONG, D_ULONG, D_SHORT, D_USHORT, D_DOUBLE, D_FLOAT, D_MONEY, D_DATE, D_CHAR, D_UNIQUE, D_STRING, D_DATA, D_ICHAR, D_INT32, D_UINT32, D_INT64, D_UINT64, D_REAL64,D_BYTE};

struct d_int
{
	char data[4];

	d_int(int32 val=0);
	d_int(const d_int& from);

	d_int& operator = (const d_int& from);
	d_int& operator = (const int32 from);

	operator int32() const;
};


#endif
