Struct randomx_bindings::vm::RandomxVm[][src]

pub struct RandomxVm<'a, T: 'a> { /* fields omitted */ }

Implementations

Calculate the RandomX hash of some data.

use randomx_bindings::*;
let flags = RandomxFlags::default();
let cache = RandomxCache::new(flags, "key".as_bytes())?;
let vm = RandomxVm::new(flags, &cache)?;
let hash = vm.hash("input".as_bytes());

Trait Implementations

Executes the destructor for this type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.