diff options
author | Justus Winter <justus@sequoia-pgp.org> | 2020-03-31 11:00:31 +0200 |
---|---|---|
committer | Justus Winter <justus@sequoia-pgp.org> | 2020-03-31 11:52:31 +0200 |
commit | 7f4eb0b55bb20b771d8ccfc5e0541ff95f83757c (patch) | |
tree | 724fe301502d11c782eed54ec14d4ebb9c4ff5f0 /openpgp/src/lib.rs | |
parent | 13da17b51764dfb285d5febdbcdee24a2d6c4021 (diff) |
openpgp: Move definition of struct PacketPile.
- Implement Default for PacketPile, add internal accessor for the
top-level.
Diffstat (limited to 'openpgp/src/lib.rs')
-rw-r--r-- | openpgp/src/lib.rs | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/openpgp/src/lib.rs b/openpgp/src/lib.rs index 880819aa..0cd474da 100644 --- a/openpgp/src/lib.rs +++ b/openpgp/src/lib.rs @@ -152,6 +152,7 @@ pub use cert::Cert; pub mod serialize; mod packet_pile; +pub use packet_pile::PacketPile; pub mod message; pub mod types; @@ -431,25 +432,6 @@ impl Packet { } } -/// A `PacketPile` holds a deserialized sequence of OpenPGP messages. -/// -/// To deserialize an OpenPGP usage, use either [`PacketParser`], -/// [`PacketPileParser`], or [`PacketPile::from_file`] (or related -/// routines). -/// -/// Normally, you'll want to convert the `PacketPile` to a Cert or a -/// `Message`. -/// -/// [`PacketParser`]: parse/struct.PacketParser.html -/// [`PacketPileParser`]: parse/struct.PacketPileParser.html -/// [`PacketPile::from_file`]: struct.PacketPile.html#method.from_file -#[derive(PartialEq, Clone)] -pub struct PacketPile { - /// At the top level, we have a sequence of packets, which may be - /// containers. - top_level: Container, -} - /// An OpenPGP message. /// /// An OpenPGP message is a structured sequence of OpenPGP packets. |