home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / cpp_libs / oath.lha / oath / src / slNodeP.cc < prev    next >
Encoding:
C/C++ Source or Header  |  1991-08-29  |  1.5 KB  |  50 lines

  1. //***************************************************************************
  2. //             OATH :: Object-oriented Abstract Type Hierarchy
  3. //***************************************************************************
  4. //
  5. //  Copyright (C) 1991, 1990  Texas Instruments Incorporated
  6. //  Permission is granted to any individual or institution
  7. //  to use, copy, modify, and distribute this software,
  8. //  provided that this complete copyright and permission notice
  9. //  is maintained, intact, in all copies and supporting documentation.
  10. //
  11. //  Texas Instruments Incorporated provides this software "as is"
  12. //  without express or implied warranty.
  13. //
  14. //***************************************************************************
  15. //  slNodeP
  16. //
  17. //  History:
  18. //    06/91  Brian M Kennedy  New macros & format; remove printDiagnostic
  19. //    10/90  Brian M Kennedy  Major Rewrite
  20. //    02/90  Brian M Kennedy  Original
  21. //
  22. //***************************************************************************
  23.  
  24. #include "copyright.h"
  25.  
  26. #include <oath/slNodeP.h>
  27.  
  28. /////////////////////////////////////////////////////////////////////////////
  29. // slNodeP Outline Definitions
  30.  
  31. // Dynamic Allocation
  32.  
  33. #ifdef OATH_HANDLE_NEW
  34.  
  35. int      slNodeP::AllocateCount = 10;
  36.  
  37. slNodeP *slNodeP::FreeList      = 0;
  38.  
  39.     void slNodeP::
  40. allocate ()
  41.    {FreeList = new slNodeP [AllocateCount];
  42.     for(int I = 0; I < AllocateCount-1; I++)
  43.     FreeList[I].Next = &FreeList[I+1];
  44.     FreeList[AllocateCount-1].Next = 0;
  45.    }
  46.  
  47. #endif
  48.  
  49. //***************************************************************************
  50.