Changeset 7010 for trunk/src/kernel32/ccollection.cpp
- Timestamp:
- Oct 11, 2001, 3:00:12 AM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/ccollection.cpp
r5848 r7010 1 /* $Id: ccollection.cpp,v 1. 6 2001-06-01 01:21:13 phaller Exp $ */1 /* $Id: ccollection.cpp,v 1.7 2001-10-11 00:59:43 phaller Exp $ */ 2 2 3 3 /* … … 780 780 781 781 782 int CHashtableLookup::getElementMap(PHASHTABLEENTRY pBuffer) 783 { 784 int iIndex = 0; 785 786 // iterate over all registered entries and dump them to the buffer 787 // giving the caller direct access to the hashtable internals. 788 for (int i = 0; 789 i < iSize; 790 i++) 791 { 792 // check if slot was occupied 793 if (parrLists[i] != NULL) 794 { 795 // walk along any entry in that linear list 796 PLINEARLISTENTRY pLLE = parrLists[i]->getFirst(); 797 798 while (pLLE) 799 { 800 PHASHTABLEENTRY pHTE = (PHASHTABLEENTRY)pLLE->pObject; 801 memcpy(&pBuffer[iIndex], pHTE, sizeof( HASHTABLEENTRY ) ); 802 iIndex++; 803 804 pLLE = parrLists[i]->getNext(pLLE); 805 } 806 } 807 } 808 809 // return number of elements copied 810 return iIndex; 811 } 812 813 782 814 void CHashtableLookup::setSize0(int iNewSize) 783 815 {
Note:
See TracChangeset
for help on using the changeset viewer.