holoscan::ClockKey
Identify a clock declaration during cold graph and plan construction.
A key owns either a clock name or the distinct omitted/default identity. It is safe to retain after the source string is destroyed. A key does not identify a live clock generation and cannot be constructed from a ClockId or ClockRef. Resolution to a live clock is a session operation.
Thread safety: distinct values may be used concurrently. Concurrent mutation and access to the same value requires external synchronization. Creating or copying a named key may allocate to own the name; queries do not allocate.
Constructors
ClockKey
Default
Create a named cold clock key
Create the omitted key that resolves to the graph or runtime default clock.
Methods
is_default
Return whether this key denotes the graph or runtime default clock.
This operation does not allocate.
Returns: true for the omitted/default identity; otherwise false.
name
Return the owned declaration name.
The view remains valid until this key is modified or destroyed. This operation does not allocate.
Returns: The declaration name, or an empty view for the default key.
Static methods
default_clock
Create the omitted key that resolves to the default clock.
This operation does not allocate.
Returns: The distinct default-clock key.
named
Create a named cold clock key.
This operation may allocate to own name.
Returns: A key that owns name.
Throws: std::bad_alloc if storage for the owned name cannot be allocated.
Parameters
Clock declaration name to copy.