Struct spacetimedb_table::indexes::RowHash
source · pub struct RowHash(pub u64);
Expand description
The content hash of a row.
Notes:
-
The hash is not cryptographically secure.
-
The hash is valid only for the lifetime of a
Table
. This entails that it should not be persisted to disk or used as a stable identifier over the network. For example, the hashing algorithm could be different on different machines based on availability of hardware instructions. Moreover, due to random seeds, when restarting from disk, the hashes may be different for the same rows.
Tuple Fields§
§0: u64
Implementations§
source§impl RowHash
impl RowHash
sourcepub fn hasher_builder() -> RandomState
pub fn hasher_builder() -> RandomState
Returns a Hasher
builder that yields the type of hashes that RowHash
stores.
Trait Implementations§
source§impl Ord for RowHash
impl Ord for RowHash
source§impl PartialEq for RowHash
impl PartialEq for RowHash
source§impl PartialOrd for RowHash
impl PartialOrd for RowHash
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for RowHash
impl Eq for RowHash
impl IsEnabled for RowHash
RowHash
is already a hash, so no need to hash again.
impl StructuralPartialEq for RowHash
Auto Trait Implementations§
impl RefUnwindSafe for RowHash
impl Send for RowHash
impl Sync for RowHash
impl Unpin for RowHash
impl UnwindSafe for RowHash
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more