cdi_key.h 558 Bytes
Newer Older
1 2
#ifndef  CDI_KEY_H
#define  CDI_KEY_H
3

4
// CDI key
5 6
typedef struct {
  int       key;          // CDI key
7
  int       nelems;       // length of buffer v.s
8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
  union {
    int i;
    double d;
    char *s;
  } v;
} cdi_key_t;


typedef struct {
  size_t     nalloc;		// number allocated >= nelems
  size_t     nelems;		// length of the array
  cdi_key_t  value[MAX_KEYS];
} cdi_keys_t;

#endif

/*
 * Local Variables:
 * c-file-style: "Java"
 * c-basic-offset: 2
 * indent-tabs-mode: nil
 * show-trailing-whitespace: t
 * require-trailing-newline: t
 * End:
 */