soroban_sdk::testutils

Trait Address

Source
pub trait Address {
    // Required method
    fn generate(env: &Env) -> Address;
}
Available on crate feature testutils only.

Required Methods§

Source

fn generate(env: &Env) -> Address

Generate a new Address.

Implementation note: this always builds the contract addresses now. This shouldn’t normally matter though, as contracts should be agnostic to the underlying Address value.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§