[−][src]Struct gdnative_core::Dictionary
A reference-counted Dictionary of Variant key-value pairs.
Methods
impl Dictionary[src]
impl Dictionarypub fn new() -> Self | [src] |
Creates an empty Dictionary.
pub fn is_empty(&self) -> bool | [src] |
Returns true if the Dictionary contains no elements.
pub fn len(&self) -> i32 | [src] |
Returns the number of elements in the Dictionary.
pub fn clear(&mut self) | [src] |
Clears the Dictionary, removing all key-value pairs.
pub fn contains(&self, key: &Variant) -> bool | [src] |
Returns true if the Dictionary contains the specified key.
pub fn contains_all(&self, keys: &VariantArray) -> bool | [src] |
Returns true if the Dictionary has all of the keys in the given array.
pub fn erase(&mut self, key: &Variant) | [src] |
Erase a key-value pair in the Dictionary by the specified key.
pub fn get(&self, key: &Variant) -> Variant | [src] |
Returns a copy of the value corresponding to the key.
pub fn set(&mut self, key: &Variant, val: &Variant) | [src] |
Sets a value to the element corresponding to the key.
pub fn get_ref(&self, key: &Variant) -> &Variant | [src] |
Returns a reference to the value corresponding to the key.
pub fn get_mut_ref(&mut self, key: &Variant) -> &mut Variant | [src] |
Returns a mutable reference to the value corresponding to the key.
pub fn to_json(&self) -> GodotString | [src] |
Returns a GodotString of the Dictionary.
pub fn keys(&self) -> VariantArray | [src] |
Returns an array of the keys in the Dictionary.
pub fn values(&self) -> VariantArray | [src] |
Returns an array of the values in the Dictionary.
pub fn get_next(&self, key: &Variant) -> &Variant | [src] |
pub fn hash(&self) -> i32 | [src] |
Return a hashed i32 value representing the dictionary's contents.
pub fn new_ref(&self) -> Dictionary | [src] |
Trait Implementations
impl ToVariant for Dictionary[src]
impl ToVariant for Dictionaryfn to_variant(&self) -> Variant | [src] |
fn from_variant(variant: &Variant) -> Option<Self> | [src] |
impl<'l> From<&'l Dictionary> for Variant[src]
impl<'l> From<&'l Dictionary> for Variantfn from(val: &'l Dictionary) -> Variant | [src] |
impl Eq for Dictionary[src]
impl Eq for Dictionaryimpl Drop for Dictionary[src]
impl Drop for Dictionaryimpl Default for Dictionary[src]
impl Default for Dictionaryimpl PartialEq<Dictionary> for Dictionary[src]
impl PartialEq<Dictionary> for Dictionaryfn eq(&self, other: &Self) -> bool | [src] |
| 1.0.0 [src] |
This method tests for !=.
impl Debug for Dictionary[src]
impl Debug for DictionaryAuto Trait Implementations
impl Send for Dictionary
impl Send for Dictionaryimpl Sync for Dictionary
impl Sync for DictionaryBlanket Implementations
impl<T> From for T[src]
impl<T> From for Timpl<T, U> Into for T where
U: From<T>, [src]
impl<T, U> Into for T where
U: From<T>, impl<T, U> TryFrom for T where
T: From<U>, [src]
impl<T, U> TryFrom for T where
T: From<U>, type Error = !
try_from)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error> | [src] |
impl<T> Borrow for T where
T: ?Sized, [src]
impl<T> Borrow for T where
T: ?Sized, impl<T> BorrowMut for T where
T: ?Sized, [src]
impl<T> BorrowMut for T where
T: ?Sized, fn borrow_mut(&mut self) -> &mut T | [src] |
impl<T, U> TryInto for T where
U: TryFrom<T>, [src]
impl<T, U> TryInto for T where
U: TryFrom<T>, type Error = <U as TryFrom<T>>::Error
try_from)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error> | [src] |
impl<T> Any for T where
T: 'static + ?Sized, [src]
impl<T> Any for T where
T: 'static + ?Sized, fn get_type_id(&self) -> TypeId | [src] |