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.

65 lines
1.5 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1991 - 1992.
  5. //
  6. // File: ORCURSOR.HXX
  7. //
  8. // Contents: Merge Cursor
  9. //
  10. // Classes: COrCursor
  11. //
  12. // History: 26-Sep-91 BartoszM Created.
  13. //
  14. //----------------------------------------------------------------------------
  15. #pragma once
  16. #include <curstk.hxx>
  17. #include <heap.hxx>
  18. #include <curheap.hxx>
  19. //+---------------------------------------------------------------------------
  20. //
  21. // Class: COrCursor
  22. //
  23. // Purpose: Boolean OR cursor, OR's cursors from the same index
  24. //
  25. // History: 26-Sep-91 BartoszM Created.
  26. // 28-Feb-92 AmyA Added HitCount()
  27. // 13-Apr-92 AmyA Added Rank()
  28. //
  29. //----------------------------------------------------------------------------
  30. class COrCursor: public CCursor
  31. {
  32. public:
  33. COrCursor( int cCursor, CCurStack& curStack );
  34. ~COrCursor() {} // heaps are deleted
  35. WORKID WorkId();
  36. WORKID NextWorkId();
  37. ULONG WorkIdCount();
  38. ULONG HitCount();
  39. LONG Rank();
  40. LONG Hit();
  41. LONG NextHit();
  42. void RatioFinished ( ULONG& denom, ULONG& num );
  43. protected:
  44. CWidHeap _widHeap;
  45. LONG _lMaxWeight; // Max Weight of any child
  46. WORKID _wid;
  47. int _iCur;
  48. };