Skip to main content

JavaHashCode

Trait JavaHashCode 

Source
pub trait JavaHashCode {
    // Required method
    fn java_hash_code(&self) -> i32;
}
Expand description

Java-compatible hashCode support for SelectMessageQueueByHash.

Java’s selector delegates to arg.hashCode(), so Rust arguments need an explicit stable contract instead of std::hash::Hash, whose output is intentionally implementation-specific.

Required Methods§

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl JavaHashCode for CheetahString

Source§

impl JavaHashCode for String

Source§

impl JavaHashCode for bool

Source§

impl JavaHashCode for i8

Source§

impl JavaHashCode for i16

Source§

impl JavaHashCode for i32

Source§

impl JavaHashCode for i64

Source§

impl JavaHashCode for isize

Source§

impl JavaHashCode for str

Source§

impl JavaHashCode for u8

Source§

impl JavaHashCode for u16

Source§

impl JavaHashCode for u32

Source§

impl JavaHashCode for u64

Source§

impl JavaHashCode for usize

Source§

impl<T> JavaHashCode for &T
where T: JavaHashCode + ?Sized,

Implementors§