17 #if !defined(OPENNURBS_MAP_INC_) 18 #define OPENNURBS_MAP_INC_ 73 ON__UINT8 m_sn_active;
74 ON__UINT8 m_id_active;
75 ON__UINT8 m_reserved1;
76 ON__UINT8 m_reserved2;
78 ON__UINT32 m_id_crc32;
100 ON__UINT64 ActiveSerialNumberCount()
const;
107 ON__UINT64 ActiveIdCount()
const;
163 struct SN_ELEMENT* FindSerialNumber(ON__UINT64 sn)
const;
213 struct SN_ELEMENT* AddSerialNumber(ON__UINT64 sn);
270 struct SN_ELEMENT* RemoveSerialNumberAndId(ON__UINT64 sn);
319 ON__UINT64 GetElements(
322 ON__UINT64 max_count,
342 bool bBuildHashTable,
355 ON__UINT64 m_maxsn = 0;
359 ON__UINT64 m_sn_count = 0;
360 ON__UINT64 m_sn_purged = 0;
368 ON__UINT64 m_snblk_list_capacity = 0;
369 ON__UINT64 m_snblk_list_count = 0;
370 class ON_SN_BLOCK** m_snblk_list =
nullptr;
377 class ON_SN_BLOCK* m_e_blk =
nullptr;
380 class ON_SN_BLOCK& m_sn_block0;
383 struct SN_ELEMENT* FindElementHelper(ON__UINT64 sn);
384 void UpdateMaxSNHelper();
385 void GarbageCollectHelper();
386 ON__UINT64 GarbageCollectMoveHelper(ON_SN_BLOCK* dst,ON_SN_BLOCK* src);
388 ON__UINT8 m_reserved1 = 0;
389 ON__UINT8 m_reserved2 = 0;
390 ON__UINT8 m_reserved3 = 0;
399 mutable ON__UINT8 m_bHashTableIsValid = 0;
401 mutable ON__UINT32 m_hash_block_count = 0;
402 mutable ON__UINT64 m_hash_capacity = 0;
404 mutable struct SN_ELEMENT*** m_hash_table_blocks =
nullptr;
407 ON__UINT64 m_active_id_count = 0;
408 ON_UUID m_inactive_id = ON_nil_uuid;
415 void Internal_HashTableInvalidate();
417 bool Internal_HashTableRemoveSerialNumberBlock(
418 const class ON_SN_BLOCK* blk
425 ON__UINT64 Internal_HashTableAddSerialNumberBlock(
426 class ON_SN_BLOCK* blk
429 void Internal_HashTableBuild()
const;
435 ON__UINT32 Internal_HashTableBlockIndex(
439 static ON__UINT32 Internal_HashTableBlockRowIndex(
446 bool bBuildTableIfNeeded
449 struct SN_ELEMENT* Internal_HashTableRemoveElement(
451 bool bRemoveFromHashBlock
454 void Internal_HashTableGrow()
const;
456 void Internal_HashTableInitialize()
const;
ON__UINT64 m_sn
Definition: opennurbs_lookup.h:65
ON_SerialNumberMap provides a way to map set of unique serial number - uuid pairs to application defi...
Definition: opennurbs_lookup.h:32
ON_UUID is a 16 byte universally unique identifier.
Definition: opennurbs_uuid.h:32
Definition: opennurbs_array.h:36
Definition: opennurbs_lookup.h:38
Definition: opennurbs_lookup.h:52
Definition: opennurbs_textlog.h:20