Trait librashader_cache::CacheKey

source ·
pub trait CacheKey {
    // Required method
    fn hash_bytes(&self) -> &[u8] ;
}
Expand description

Trait for objects that can be used as part of a key for a cached object.

Required Methods§

source

fn hash_bytes(&self) -> &[u8]

Get a byte representation of the object that will be fed into the hash.

Implementations on Foreign Types§

source§

impl CacheKey for &str

source§

fn hash_bytes(&self) -> &[u8]

source§

impl CacheKey for &[u8]

source§

fn hash_bytes(&self) -> &[u8]

source§

impl CacheKey for i32

source§

fn hash_bytes(&self) -> &[u8]

source§

impl CacheKey for u32

source§

fn hash_bytes(&self) -> &[u8]

source§

impl CacheKey for Vec<u8>

source§

fn hash_bytes(&self) -> &[u8]

source§

impl CacheKey for Vec<u32>

source§

fn hash_bytes(&self) -> &[u8]

Implementors§