pub struct NameHash {
pub md5: [u64; 2],
pub java_hash: i32,
}Expand description
Precomputed hash of a resource name for both random implementations.
Holds an MD5 digest (for Xoroshiro) and a Java String.hashCode() (for Legacy).
All fields are computed at compile time when used with const bindings:
ⓘ
const OFFSET: NameHash = NameHash::new("minecraft:offset");Fields§
§md5: [u64; 2]MD5 digest split into two big-endian u64s (matches md5 crate output layout).
java_hash: i32Java String.hashCode() for ASCII strings.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for NameHash
impl RefUnwindSafe for NameHash
impl Send for NameHash
impl Sync for NameHash
impl Unpin for NameHash
impl UnsafeUnpin for NameHash
impl UnwindSafe for NameHash
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