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) -> &str
pub fn extend(&mut self, other: &Dictionary)
sourcepub fn as_hashmap(&self) -> &LinkedHashMap<Vec<u8>, Object>
pub fn as_hashmap(&self) -> &LinkedHashMap<Vec<u8>, Object>
Return a reference to the inner LinkedHashMap
.
sourcepub fn as_hashmap_mut(&mut self) -> &mut LinkedHashMap<Vec<u8>, Object>
pub fn as_hashmap_mut(&mut self) -> &mut LinkedHashMap<Vec<u8>, Object>
Return a mut reference to the inner LinkedHashMap
.
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 PartialEq for Dictionary
impl PartialEq for Dictionary
source§fn eq(&self, other: &Dictionary) -> bool
fn eq(&self, other: &Dictionary) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for Dictionary
Auto Trait Implementations§
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