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 has_type(&self, type_name: &[u8]) -> bool
pub fn get_type(&self) -> Result<&[u8]>
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 duplicate of the value. Read more
1.0.0 (const: unstable) · 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
Source§fn eq(&self, other: &Dictionary) -> bool
fn eq(&self, other: &Dictionary) -> bool
Tests for
self and other values to be equal, and is used by ==.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 UnsafeUnpin 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§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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<R, P> ReadPrimitive<R> for P
impl<R, P> ReadPrimitive<R> for P
Source§fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
fn read_from_little_endian(read: &mut R) -> Result<Self, Error>
Read this value from the supplied reader. Same as
ReadEndian::read_from_little_endian().