Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

64 lines
1.2 KiB

  1. /******************************************************************************
  2. Copyright (c) 1999 Microsoft Corporation
  3. Module Name:
  4. hashlist.h
  5. Abstract:
  6. Revision History:
  7. Eugene Mesgar (eugenem) 6/16/99
  8. created
  9. ******************************************************************************/
  10. #ifndef __CFLHASHLIST__
  11. #define __CFLHASHLIST__
  12. #include "flstructs.h"
  13. #define LARGEST_HASH_SIZE 1003
  14. class CFLHashList
  15. {
  16. LPVOID m_pBasePointer;
  17. LONG m_lNumElements;
  18. LONG m_lNumHashSpots;
  19. LONG m_ilOpenEntry;
  20. DWORD m_dwSize;
  21. ListHeader *m_pListHeader;
  22. ListEntry *m_pNodeIndex;
  23. BlobHeader *m_pBlobHeader;
  24. DWORD *m_paHashArray; // base index pointer
  25. HANDLE m_hHeapToUse;
  26. public:
  27. CFLHashList();
  28. CFLHashList(HANDLE hHeap);
  29. virtual ~CFLHashList();
  30. BOOL Init(LONG lNumNodes, DWORD dwNumChars);
  31. BOOL AddFile(LPTSTR szFile, TCHAR chType);
  32. BOOL CleanUpMemory();
  33. DWORD CreatePathElem( LPTSTR pszData, BYTE *pbLargeBuffer );
  34. DWORD GetSize();
  35. LPVOID GetBasePointer();
  36. BOOL IsPrime(DWORD dwNumber);
  37. DWORD GetNextHighestPrime( DWORD dwNumber );
  38. };
  39. #endif