2009-06-11 14:49:15 +00:00
|
|
|
/* $PostgreSQL: pgsql/contrib/cube/cubedata.h,v 1.10 2009/06/11 14:48:50 momjian Exp $ */
|
2006-03-11 04:38:42 +00:00
|
|
|
|
2002-09-12 00:26:00 +00:00
|
|
|
#define CUBE_MAX_DIM (100)
|
2007-02-27 23:48:10 +00:00
|
|
|
|
2001-03-22 04:01:46 +00:00
|
|
|
typedef struct NDBOX
|
|
|
|
{
|
2007-02-27 23:48:10 +00:00
|
|
|
int32 vl_len_; /* varlena header (do not touch directly!) */
|
2001-03-22 04:01:46 +00:00
|
|
|
unsigned int dim;
|
2002-08-29 23:03:58 +00:00
|
|
|
double x[1];
|
2009-06-11 14:49:15 +00:00
|
|
|
} NDBOX;
|
2007-03-07 21:21:12 +00:00
|
|
|
|
|
|
|
#define DatumGetNDBOX(x) ((NDBOX*)DatumGetPointer(x))
|
|
|
|
#define PG_GETARG_NDBOX(x) DatumGetNDBOX( PG_DETOAST_DATUM(PG_GETARG_DATUM(x)) )
|
|
|
|
#define PG_RETURN_NDBOX(x) PG_RETURN_POINTER(x)
|