home *** CD-ROM | disk | FTP | other *** search
/ The Devil's Doorknob BBS Capture (1996-2003) / devilsdoorknobbbscapture1996-2003.iso / Dloads / OTHERUTI / TCPP10-8.ZIP / CLASSINC.ZIP / RESOURCE.H < prev    next >
C/C++ Source or Header  |  1990-09-26  |  3KB  |  103 lines

  1. #ifndef __RESOURCE_H
  2. #define __RESOURCE_H
  3.  
  4. //
  5. // This file contains proprietary information of Borland International.
  6. // Copying or reproduction without prior written approval is prohibited.
  7. //
  8. // Copyright (c) 1990
  9. // Borland International
  10. // 1800 Scotts Valley Dr.
  11. // Scotts Valley, CA 95066
  12. // (408) 438-8400
  13. //
  14.  
  15. // Contents ----------------------------------------------------------------
  16. //
  17. //      DESIGN_LIMIT_ON_DEFAULT_HASH_TABLE_SIZE
  18. //      DEFAULT_HASH_TABLE_SIZE
  19. //
  20. //      DESIGN_LIMIT_ON_DEFAULT_BAG_SIZE
  21. //      DEFAULT_BAG_SIZE
  22. //
  23. //      DESIGN_LIMIT_ON_DEFAULT_SET_SIZE
  24. //      DEFAULT_SET_SIZE
  25. //
  26. // Description
  27. //
  28. //      Defines resource constants for C++ class library.
  29. //
  30. // End ---------------------------------------------------------------------
  31.  
  32. // Interface Dependencies ---------------------------------------------------
  33.  
  34. #ifndef __LIMITS_H
  35. #include <limits.h>
  36. #define __LIMITS_H
  37. #endif
  38.  
  39. // End Interface Dependencies ------------------------------------------------
  40.  
  41. // LiteralSection ----------------------------------------------------------
  42. //
  43. //      hash table size
  44. //
  45. // Description
  46. //
  47. //      Defines the limit on a hash table's size and the default size.
  48. //      Also defines limits and defaults for derived types of class HashTable.
  49. //
  50. // End ---------------------------------------------------------------------
  51.  
  52. #define DESIGN_LIMIT_ON_DEFAULT_HASH_TABLE_SIZE     UINT_MAX
  53.  
  54. //
  55. //      The hash table size is defined as a sizeType, which is an 
  56. //      unsigned int.
  57. //
  58.  
  59. #define DEFAULT_HASH_TABLE_SIZE                     111
  60.  
  61. //
  62. //      We make a fair size default hash table.  If you care to change
  63. //      the default size, you may do so without harm, as long as your
  64. //      default value does not exceed the design limit on the maximum
  65. //      size for a hash table.  Keep in mind that a hash table is more
  66. //      efficient if the size is a prime number.
  67. //
  68.  
  69. #define DESIGN_LIMIT_ON_DEFAULT_BAG_SIZE                                    (\
  70.                                 DESIGN_LIMIT_ON_DEFAULT_HASH_TABLE_SIZE     \
  71.                                                                             )
  72. //
  73. //      Class Bag is derived from class HashTable and therefore gets the
  74. //      same design limit.
  75. //
  76.  
  77. #define DEFAULT_BAG_SIZE                            29
  78.  
  79. //
  80. //      Bags are usually smaller than hash tables.  Of course, if this
  81. //      were a grocery bag, the default would be much smaller.
  82. //
  83.  
  84. #define DESIGN_LIMIT_ON_DEFAULT_SET_SIZE                                    (\
  85.                                 DESIGN_LIMIT_ON_DEFAULT_BAG_SIZE            \
  86.                                                                             )
  87. //
  88. //      Class Set is derived from class Bag and therefore gets the
  89. //      same design limit.
  90. //
  91.  
  92. #define DEFAULT_SET_SIZE                            29
  93.  
  94. //
  95. //      Bags and sets are usually the same size.
  96. //
  97.  
  98. // End LiteralSection hash table size //
  99.  
  100. #endif // ifndef __RESOURCE_H //
  101.  
  102.  
  103.