/***********************************************************************
* *
* This software is part of the ast package *
* Copyright (c) 1985-2011 AT&T Intellectual Property *
* and is licensed under the *
* Eclipse Public License, Version 1.0 *
* by AT&T Intellectual Property *
* *
* A copy of the License is available at *
* (with md5 checksum b35adb5213ca9657e911e9befb180842) *
* *
* Information and Software Systems Research *
* AT&T Research *
* Florham Park NJ *
* *
* Glenn Fowler <gsf@research.att.com> *
* David Korn <dgk@research.att.com> *
* Phong Vo <kpv@research.att.com> *
* *
***********************************************************************/
#ifndef _CDT_H
/* Public interface for the dictionary library
**
** Written by Kiem-Phong Vo
*/
#ifndef CDT_VERSION
#ifdef _API_ast
#else
#endif /*_AST_api*/
#endif /*CDT_VERSION*/
#ifndef AST_PLUGIN_VERSION
#define AST_PLUGIN_VERSION(v) (v)
#endif
#if _PACKAGE_ast
#include <ast_std.h>
#else
#include <ast_common.h>
#include <string.h>
#endif
/* commonly used integers */
/* type of an integer with the same size as a pointer */
/* various types used by CDT */
};
struct _dtlink_s
{
#if CDT_VERSION < 20111111L
union
} hl;
#else
union
} rh;
union
unsigned int __hash; /* hash value of object */
} lh;
#endif
};
/* private structure to hold an object */
struct _dthold_s
};
/* method to manipulate dictionary structure */
struct _dtmethod_s
};
/* structure to hold methods that manipulate an object */
struct _dtdisc_s
};
#ifdef offsetof
#else
#endif
/* the dictionary structure itself */
struct _dt_s
};
/* structure to get status of a dictionary */
struct _dtstat_s
};
/* supported storage methods */
/* asserts to dtdisc() to improve performance when changing disciplines */
/* operation types */
#define DT_TOANNOUNCE (DT_INSERT|DT_DELETE|DT_SEARCH|DT_NEXT|DT_PREV|DT_FIRST|DT_LAST|DT_MATCH|DT_ATTACH|DT_DETACH|DT_APPEND|DT_ATLEAST|DT_ATMOST|DT_REMOVE)
/* these bits may combine with the DT_METHODS and DT_OPERATIONS bits */
/* the actual event will be this bit */
/* combined with the operation bit */
/* events for discipline and method event-handling functions */
_BEGIN_EXTERNS_ /* data structures and functions */
#if _BLD_cdt && defined(__EXPORT__)
#define extern __EXPORT__
#endif
#if !_BLD_cdt && defined(__IMPORT__)
#define extern __IMPORT__
#endif
extern Dtmethod_t* Dtset;
extern Dtmethod_t* Dtbag;
extern Dtmethod_t* Dtoset;
extern Dtmethod_t* Dtobag;
extern Dtmethod_t* Dtlist;
extern Dtmethod_t* Dtstack;
extern Dtmethod_t* Dtqueue;
extern Dtmethod_t* Dtdeque;
#if _PACKAGE_ast /* dtplugin() for proprietary and non-standard methods -- requires -ldll */
#else
#if CDTPROPRIETARY
extern Dtmethod_t* Dtrhset;
extern Dtmethod_t* Dtrhbag;
#endif /*CDTPROPRIETARY*/
#endif /*_PACKAGE_ast*/
#undef extern
#if _BLD_cdt && defined(__EXPORT__)
#define extern __EXPORT__
#endif
/* deal with upward binary compatibility (operation bit translation, etc.) */
#undef extern
#if _PACKAGE_ast && !defined(_CDTLIB_H)
#if _BLD_dll && defined(__EXPORT__)
#define extern __EXPORT__
#endif
extern void* dllmeth(const char*, const char*, unsigned long);
#undef extern
#endif
/* internal functions for translating among holder, object and key */
#endif /* _CDT_H */