MemoBehavior

Trait MemoBehavior 

Source
pub trait MemoBehavior {
Show 13 methods // Required methods fn new(memo_type: &str, value: Option<&str>) -> Result<Self, Box<dyn Error>> where Self: Sized; fn id(input: &str) -> Self where Self: Sized; fn text(input: &str) -> Self where Self: Sized; fn text_buffer(input: Vec<u8>) -> Self where Self: Sized; fn hash_buffer(input: Vec<u8>) -> Self where Self: Sized; fn return_hash(input: Vec<u8>) -> Self where Self: Sized; fn none() -> Self where Self: Sized; fn value(&self) -> Result<MemoValue, &'static str>; fn from_xdr_object(object: Memo) -> Result<Self, &'static str> where Self: Sized; fn to_xdr_object(&self) -> Option<Memo>; fn _validate_id_value(value: &str) -> Result<(), String>; fn _validate_text_value(value: &str); fn _validate_hash_value(value: &[u8]);
}

Required Methods§

Source

fn new(memo_type: &str, value: Option<&str>) -> Result<Self, Box<dyn Error>>
where Self: Sized,

Source

fn id(input: &str) -> Self
where Self: Sized,

Source

fn text(input: &str) -> Self
where Self: Sized,

Source

fn text_buffer(input: Vec<u8>) -> Self
where Self: Sized,

Source

fn hash_buffer(input: Vec<u8>) -> Self
where Self: Sized,

Source

fn return_hash(input: Vec<u8>) -> Self
where Self: Sized,

Source

fn none() -> Self
where Self: Sized,

Source

fn value(&self) -> Result<MemoValue, &'static str>

Source

fn from_xdr_object(object: Memo) -> Result<Self, &'static str>
where Self: Sized,

Source

fn to_xdr_object(&self) -> Option<Memo>

Source

fn _validate_id_value(value: &str) -> Result<(), String>

Source

fn _validate_text_value(value: &str)

Source

fn _validate_hash_value(value: &[u8])

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§