Trait StellarTypeToString

Source
pub trait StellarTypeToString<T, E: From<Utf8Error>> {
    // Required method
    fn as_encoded_string(&self) -> Result<String, E>;
}
Expand description

A trait used to convert any Stellar specific type T as a String This also immediately converts the standard Error to a user-defined Error E Helpful for functions that will accept:

  • the Stellar type itself;
  • encoded &str version of the Stellar type;
  • a Vec<u8> version of th Stellar type

Required Methods§

Implementations on Foreign Types§

Source§

impl<E: From<Utf8Error>> StellarTypeToString<ClaimableBalanceId, E> for &str

Source§

impl<E: From<Utf8Error>> StellarTypeToString<PublicKey, E> for &str

Source§

impl<E: From<Utf8Error>> StellarTypeToString<PublicKey, E> for Vec<u8>

Implementors§