pub struct AttachmentRef<'a> { /* private fields */ }Expand description
An immutable reference to an Attachment. Implements Deref to &Attachment
Implementations§
Source§impl AttachmentRef<'_>
impl AttachmentRef<'_>
Sourcepub fn database(&self) -> &Database
pub fn database(&self) -> &Database
Get an immutable reference to the database that owns this attachment.
Sourcepub fn entries(
&self,
include_historical: bool,
) -> impl Iterator<Item = EntryRef<'_>>
pub fn entries( &self, include_historical: bool, ) -> impl Iterator<Item = EntryRef<'_>>
Get an iterator over the entries that reference this attachment.
If include_historical is false, only returns entries that currently reference this
attachment. If include_historical is true, also returns old versions of entries that
reference this attachment, even if they have been modified to no longer reference it.
Methods from Deref<Target = Attachment>§
Sourcepub fn id(&self) -> AttachmentId
pub fn id(&self) -> AttachmentId
Get the ID of this attachment.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for AttachmentRef<'a>
impl<'a> RefUnwindSafe for AttachmentRef<'a>
impl<'a> Send for AttachmentRef<'a>
impl<'a> Sync for AttachmentRef<'a>
impl<'a> Unpin for AttachmentRef<'a>
impl<'a> UnsafeUnpin for AttachmentRef<'a>
impl<'a> UnwindSafe for AttachmentRef<'a>
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