Live Cells C++
Reactive Programming for C++
|
Defines the interface for a key which uniquely identifies a cell. More...
#include <keys.hpp>
Public Member Functions | |
virtual bool | eq (const key &k) const noexcept=0 |
Compare this key to another key for equality. | |
virtual std::size_t | hash () const noexcept=0 |
Compute the hash code for this key. | |
virtual bool | is_unique () const noexcept |
Is this a unique key? | |
Defines the interface for a key which uniquely identifies a cell.
Compare this key to another key for equality.
k | The key to compare to |
true
if this is equal to \aa k. Implemented in live_cells::constant_key< T >, live_cells::unique_key, live_cells::value_key< T, Ts >, live_cells::value_key< key_ref >, live_cells::value_key< key_ref, key_ref >, and live_cells::value_key< T >.
|
pure virtualnoexcept |
Compute the hash code for this key.
Implemented in live_cells::constant_key< T >, live_cells::unique_key, live_cells::value_key< T, Ts >, live_cells::value_key< key_ref >, live_cells::value_key< key_ref, key_ref >, and live_cells::value_key< T >.
Is this a unique key?
A key is unique if it is identified by a single key
instance.
true
if this key is unique. Reimplemented in live_cells::unique_key.