Trait pgp::composed::Deserializable
source · pub trait Deserializable: Sized {
// Required method
fn from_packets<'a, I: Iterator<Item = Result<Packet>> + 'a>(
packets: Peekable<I>
) -> Box<dyn Iterator<Item = Result<Self>> + 'a>;
// Provided methods
fn from_bytes(bytes: impl Read) -> Result<Self> { ... }
fn from_string(input: &str) -> Result<(Self, BTreeMap<String, String>)> { ... }
fn from_string_many<'a>(
input: &'a str
) -> Result<(Box<dyn Iterator<Item = Result<Self>> + 'a>, BTreeMap<String, String>)> { ... }
fn from_armor_single<R: Read + Seek>(
input: R
) -> Result<(Self, BTreeMap<String, String>)> { ... }
fn from_armor_many<'a, R: Read + Seek + 'a>(
input: R
) -> Result<(Box<dyn Iterator<Item = Result<Self>> + 'a>, BTreeMap<String, String>)> { ... }
fn from_bytes_many<'a>(
bytes: impl Read + 'a
) -> Box<dyn Iterator<Item = Result<Self>> + 'a> { ... }
}
Required Methods§
Provided Methods§
sourcefn from_bytes(bytes: impl Read) -> Result<Self>
fn from_bytes(bytes: impl Read) -> Result<Self>
Parse a single byte encoded composition.
sourcefn from_string(input: &str) -> Result<(Self, BTreeMap<String, String>)>
fn from_string(input: &str) -> Result<(Self, BTreeMap<String, String>)>
Parse a single armor encoded composition.
sourcefn from_string_many<'a>(
input: &'a str
) -> Result<(Box<dyn Iterator<Item = Result<Self>> + 'a>, BTreeMap<String, String>)>
fn from_string_many<'a>( input: &'a str ) -> Result<(Box<dyn Iterator<Item = Result<Self>> + 'a>, BTreeMap<String, String>)>
Parse an armor encoded list of compositions.
sourcefn from_armor_single<R: Read + Seek>(
input: R
) -> Result<(Self, BTreeMap<String, String>)>
fn from_armor_single<R: Read + Seek>( input: R ) -> Result<(Self, BTreeMap<String, String>)>
Armored ascii data.
Object Safety§
This trait is not object safe.