home *** CD-ROM | disk | FTP | other *** search
/ Source Code 1992 March / Source_Code_CD-ROM_Walnut_Creek_March_1992.iso / usenet / altsrcs / 1 / 1156 / dyn.h < prev    next >
Encoding:
C/C++ Source or Header  |  1990-12-28  |  1.1 KB  |  48 lines

  1. /*
  2.  * This file is part of libdyn.a, the C Dynamic Object library.  It
  3.  * contains the public header file.
  4.  *
  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.
  8.  *
  9.  * Written by Barr3y Jaspan, Student Information Processing Board (SIPB)
  10.  * and MIT-Project Athena, 1989.
  11.  */
  12.  
  13.  
  14. /*
  15.  * dyn.h -- header file to be included by programs linking against
  16.  * libdyn.a.
  17.  */
  18.  
  19. #ifndef _Dyn_h
  20. #define _Dyn_h
  21.  
  22. #ifdef notdef
  23. typedef void *DynPtr;
  24. #else
  25. typedef char *DynPtr;
  26. #endif
  27.  
  28. typedef struct _DynObject DynObjectRec, *DynObject;
  29.  
  30. /* Function macros */
  31. #define DynHigh(obj)    (DynSize(obj) - 1)
  32. #define DynLow(obj)    (0)
  33.  
  34. /* Return status codes */
  35. #define DYN_OK        -1000
  36. #define DYN_NOMEM    -1001
  37. #define DYN_BADINDEX    -1002
  38. #define DYN_BADVALUE    -1003
  39.      
  40. /* Function declarations */
  41. DynObject     DynCreate();
  42. int        DynAdd(), DynDelete(), DynDestroy(), DynDebug();
  43. int        DynInsert(), DynParanoid();
  44. DynPtr        DynGet();
  45.  
  46. #endif /* _Dyn_h */
  47. /* DO NOT ADD ANYTHING AFTER THIS #endif */
  48.