Struct lopdf::Dictionary
source · pub struct Dictionary(/* private fields */);
Expand description
Dictionary object.
Implementations§
source§impl Dictionary
impl Dictionary
pub fn new() -> Dictionary
pub fn has(&self, key: &[u8]) -> bool
pub fn get(&self, key: &[u8]) -> Result<&Object>
sourcepub fn get_deref<'a>(
&'a self,
key: &[u8],
doc: &'a Document,
) -> Result<&'a Object>
pub fn get_deref<'a>( &'a self, key: &[u8], doc: &'a Document, ) -> Result<&'a Object>
Extract object from dictionary, dereferencing the object if it is a reference.
pub fn get_mut(&mut self, key: &[u8]) -> Result<&mut Object>
pub fn set<K, V>(&mut self, key: K, value: V)
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
pub fn remove(&mut self, key: &[u8]) -> Option<Object>
pub fn type_name(&self) -> Result<&str>
pub fn type_is(&self, type_name: &[u8]) -> bool
pub fn iter(&self) -> Iter<'_, Vec<u8>, Object>
pub fn iter_mut(&mut self) -> IterMut<'_, Vec<u8>, Object>
pub fn get_font_encoding(&self, doc: &Document) -> Result<Encoding<'_>>
pub fn extend(&mut self, other: &Dictionary)
Trait Implementations§
source§impl Clone for Dictionary
impl Clone for Dictionary
source§fn clone(&self) -> Dictionary
fn clone(&self) -> Dictionary
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for Dictionary
impl Debug for Dictionary
source§impl Default for Dictionary
impl Default for Dictionary
source§fn default() -> Dictionary
fn default() -> Dictionary
Returns the “default value” for a type. Read more
source§impl From<Dictionary> for Object
impl From<Dictionary> for Object
source§fn from(dict: Dictionary) -> Self
fn from(dict: Dictionary) -> Self
Converts to this type from the input type.
source§impl<K: Into<Vec<u8>>> FromIterator<(K, Object)> for Dictionary
impl<K: Into<Vec<u8>>> FromIterator<(K, Object)> for Dictionary
source§impl<'a> IntoIterator for &'a Dictionary
impl<'a> IntoIterator for &'a Dictionary
source§impl<'a> IntoIterator for &'a mut Dictionary
impl<'a> IntoIterator for &'a mut Dictionary
source§impl IntoIterator for Dictionary
impl IntoIterator for Dictionary
source§impl PartialEq for Dictionary
impl PartialEq for Dictionary
impl StructuralPartialEq for Dictionary
Auto Trait Implementations§
impl Freeze for Dictionary
impl RefUnwindSafe for Dictionary
impl Send for Dictionary
impl Sync for Dictionary
impl Unpin for Dictionary
impl UnwindSafe for Dictionary
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more