2 * This file is part of libdyn.a, the C Dynamic Object library. It
3 * contains the public header file.
5 * There are no restrictions on this code; however, if you make any
6 * changes, I request that you document them so that I do not get
7 * credit or blame for your modifications.
9 * Written by Barr3y Jaspan, Student Information Processing Board (SIPB)
10 * and MIT-Project Athena, 1989.
15 * dyn.h -- header file to be included by programs linking against
22 /* Reliance on <sysdep.h> for __P() below makes this unsuitable for use
23 * outside of the Zephyr source tree. */
27 typedef struct _DynObject *DynObject;
30 #define DynHigh(obj) (DynSize(obj) - 1)
31 #define DynLow(obj) (0)
34 #define memmove(a, b, c) bcopy(b, a, c)
37 /* Return status codes */
39 #define DYN_NOMEM -1001
40 #define DYN_BADINDEX -1002
41 #define DYN_BADVALUE -1003
43 /* Function declarations */
44 int DynAppend __P((DynObject obj, DynPtr els, int num));
45 int DynAdd __P((DynObject obj, DynPtr el));
46 DynObject DynCreate __P((int el_size, int inc));
47 int DynDebug __P((DynObject obj, int state));
48 int DynDelete __P((DynObject obj, int idx));
49 int DynDestroy __P((DynObject obj));
50 DynPtr DynGet __P((DynObject obj, int num));
51 int DynInsert __P((DynObject obj, int idx, DynPtr els, int num));
52 int DynParanoid __P((DynObject obj, int state));
53 int DynSize __P((DynObject obj));
56 /* DO NOT ADD ANYTHING AFTER THIS #endif */