Struct graphgate_schema::KeyFields [−][src]
Methods from Deref<Target = IndexMap<Name, KeyFields>>
pub fn capacity(&self) -> usize
[src]
Computes in O(1) time.
pub fn hasher(&self) -> &S
[src]
Return a reference to the map’s BuildHasher
.
pub fn len(&self) -> usize
[src]
Return the number of key-value pairs in the map.
Computes in O(1) time.
pub fn is_empty(&self) -> bool
[src]
Returns true if the map contains no elements.
Computes in O(1) time.
pub fn iter(&self) -> Iter<'_, K, V>
[src]
Return an iterator over the key-value pairs of the map, in their order
pub fn keys(&self) -> Keys<'_, K, V>
[src]
Return an iterator over the keys of the map, in their order
pub fn values(&self) -> Values<'_, K, V>
[src]
Return an iterator over the values of the map, in their order
pub fn contains_key<Q>(&self, key: &Q) -> bool where
Q: Hash + Equivalent<K> + ?Sized,
[src]
Q: Hash + Equivalent<K> + ?Sized,
Return true
if an equivalent to key
exists in the map.
Computes in O(1) time (average).
pub fn get<Q>(&self, key: &Q) -> Option<&V> where
Q: Hash + Equivalent<K> + ?Sized,
[src]
Q: Hash + Equivalent<K> + ?Sized,
Return a reference to the value stored for key
, if it is present,
else None
.
Computes in O(1) time (average).
pub fn get_key_value<Q>(&self, key: &Q) -> Option<(&K, &V)> where
Q: Hash + Equivalent<K> + ?Sized,
[src]
Q: Hash + Equivalent<K> + ?Sized,
Return references to the key-value pair stored for key
,
if it is present, else None
.
Computes in O(1) time (average).
pub fn get_full<Q>(&self, key: &Q) -> Option<(usize, &K, &V)> where
Q: Hash + Equivalent<K> + ?Sized,
[src]
Q: Hash + Equivalent<K> + ?Sized,
Return item index, key and value
pub fn get_index_of<Q>(&self, key: &Q) -> Option<usize> where
Q: Hash + Equivalent<K> + ?Sized,
[src]
Q: Hash + Equivalent<K> + ?Sized,
Return item index, if it exists in the map
pub fn get_index(&self, index: usize) -> Option<(&K, &V)>
[src]
Get a key-value pair by index
Valid indices are 0 <= index < self.len()
Computes in O(1) time.
pub fn first(&self) -> Option<(&K, &V)>
[src]
Get the first key-value pair
Computes in O(1) time.
pub fn last(&self) -> Option<(&K, &V)>
[src]
Get the last key-value pair
Computes in O(1) time.
Trait Implementations
impl Debug for KeyFields
[src]
impl Deref for KeyFields
[src]
type Target = IndexMap<Name, KeyFields>
The resulting type after dereferencing.
fn deref(&self) -> &Self::Target
[src]
impl Eq for KeyFields
[src]
impl PartialEq<KeyFields> for KeyFields
[src]
impl StructuralEq for KeyFields
[src]
impl StructuralPartialEq for KeyFields
[src]
Auto Trait Implementations
impl RefUnwindSafe for KeyFields
impl Send for KeyFields
impl Sync for KeyFields
impl Unpin for KeyFields
impl UnwindSafe for KeyFields
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<Q, K> Equivalent<K> for Q where
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
[src]
K: Borrow<Q> + ?Sized,
Q: Eq + ?Sized,
pub fn equivalent(&self, key: &K) -> bool
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,