![]() |
Open CASCADE Technology Reference Manual 8.0.0
|
Unique node identifier within a BRepGraph. More...
#include <BRepGraph_UID.hxx>
Public Member Functions | |
| BRepGraph_UID () | |
| Default: invalid UID (counter = 0 is the invalid sentinel). | |
| BRepGraph_UID (const BRepGraph_NodeId::Kind theKind, const size_t theCounter, const uint32_t theGeneration) | |
| Construct a valid UID. Called internally by BRepGraph::allocateUID(). | |
| bool | IsValid () const |
| BRepGraph_NodeId::Kind | Kind () const |
| size_t | Counter () const |
| uint32_t | Generation () const |
| bool | IsTopology () const |
| bool | IsAssembly () const |
| bool | operator== (const BRepGraph_UID &theOther) const |
| Equality: Identity = (Kind, Counter). Generation excluded. Two invalid UIDs are equal. | |
| bool | operator!= (const BRepGraph_UID &theOther) const |
| bool | operator< (const BRepGraph_UID &theOther) const |
| size_t | HashValue () const |
| Hash value: f(Kind, Counter). | |
Static Public Member Functions | |
| static BRepGraph_UID | Invalid () |
| Factory: returns an explicitly invalid UID. | |
Unique node identifier within a BRepGraph.
Identity = (Kind, Counter). Two nodes of different kinds may share a counter value but their UIDs are distinct. Within one kind, counter values never repeat (monotonic, never resets).
Generation is NOT part of identity; it indicates which BRepGraph::Clear() cycle produced this UID (for stale-reference detection).
Trivially copyable, cheap to pass by value.
Entity UIDs (BRepGraph_UID) and reference UIDs (BRepGraph_RefUID) share a single monotonic counter (BRepGraph_Data::myNextUIDCounter). To persist a BRepGraph across sessions:
|
inline |
Default: invalid UID (counter = 0 is the invalid sentinel).
|
inline |
Construct a valid UID. Called internally by BRepGraph::allocateUID().
|
inline |
|
inline |
|
inline |
Hash value: f(Kind, Counter).
|
inlinestatic |
Factory: returns an explicitly invalid UID.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Equality: Identity = (Kind, Counter). Generation excluded. Two invalid UIDs are equal.