Struct sequoia_openpgp::packet::Container
source · pub struct Container { /* private fields */ }
Expand description
Holds packet bodies.
This is used by OpenPGP container packets, like the compressed data packet, to store the containing packets.
Implementations§
source§impl Container
impl Container
sourcepub fn children_ref(&self) -> Option<&[Packet]>
pub fn children_ref(&self) -> Option<&[Packet]>
Returns a reference to this Packet’s children.
Returns None
if the body is not structured.
sourcepub fn children_mut(&mut self) -> Option<&mut Vec<Packet>>
pub fn children_mut(&mut self) -> Option<&mut Vec<Packet>>
Returns a mutable reference to this Packet’s children.
Returns None
if the body is not structured.
sourcepub fn descendants(&self) -> Option<Iter<'_>>
pub fn descendants(&self) -> Option<Iter<'_>>
Returns an iterator over the packet’s descendants. The descendants are visited in depth-first order.
Returns None
if the body is not structured.
sourcepub fn children(&self) -> Option<Iter<'_, Packet>>
pub fn children(&self) -> Option<Iter<'_, Packet>>
Returns an iterator over the packet’s immediate children.
Returns None
if the body is not structured.
sourcepub fn into_children(self) -> Option<IntoIter<Packet>>
pub fn into_children(self) -> Option<IntoIter<Packet>>
Returns an IntoIter
over the packet’s immediate children.
Returns None
if the body is not structured.
Trait Implementations§
source§impl PartialEq for Container
impl PartialEq for Container
impl Eq for Container
Auto Trait Implementations§
impl Freeze for Container
impl RefUnwindSafe for Container
impl Send for Container
impl Sync for Container
impl Unpin for Container
impl UnwindSafe for Container
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)