Trait redgold_schema::SafeOption
source · pub trait SafeOption<T> {
// Required methods
fn safe_get(&self) -> Result<&T, ErrorInfo>;
fn safe_get_msg<S: Into<String>>(&self, msg: S) -> Result<&T, ErrorInfo>;
fn ok_msg(self, err: impl Into<String>) -> Result<T, ErrorInfo>;
}Required Methods§
fn safe_get(&self) -> Result<&T, ErrorInfo>
fn safe_get_msg<S: Into<String>>(&self, msg: S) -> Result<&T, ErrorInfo>
fn ok_msg(self, err: impl Into<String>) -> Result<T, ErrorInfo>
Object Safety§
This trait is not object safe.