Skip to main content

Standard

Struct Standard 

Source
pub struct Standard<K, V> { /* private fields */ }

Implementations§

Source§

impl<K: Clone + Ord, V: Clone> Standard<K, V>

Source

pub fn new() -> Self

Source

pub fn len(&self) -> usize

Source

pub fn is_empty(&self) -> bool

Source

pub fn get(&self, key: &K) -> Option<&V>

Source

pub fn find_entry(&self, key: &K) -> Option<(&K, &V)>

Java S.find.

Source

pub fn assoc_value(&self, key: K, value: V) -> Self

Source

pub fn dissoc_value(&self, key: &K) -> Self

Source

pub fn iter(&self) -> Iter<'_, K, V>

Source

pub fn nth_entry(&self, index: usize) -> Option<&Node<K, V>>

Java Base.nth (order-statistic select), bounds-checked.

Source

pub fn index_of_key(&self, key: &K) -> Option<usize>

Java S.indexOf (order-statistic rank).

Source

pub fn inclusive_floor_index(&self, key: &K) -> Option<usize>

Java Base.inclusiveFloorIndex.

Source

pub fn ceil_index(&self, key: &K) -> Option<usize>

Java Base.ceilIndex.

Source

pub fn slice(&self, min: &K, max: &K) -> Self

Source

pub fn map_values<U: Clone>(&self, f: impl Fn(&K, &V) -> U) -> Standard<K, U>

Trait Implementations§

Source§

impl<K: Clone, V: Clone> Clone for Standard<K, V>

Source§

fn clone(&self) -> Standard<K, V>

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl<K: Debug, V: Debug> Debug for Standard<K, V>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<K, V> Default for Standard<K, V>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl<K: Clone + Ord, V: Clone> FromIterator<(K, V)> for Standard<K, V>

Source§

fn from_iter<T: IntoIterator<Item = (K, V)>>(it: T) -> Self

Creates a value from an iterator. Read more
Source§

impl<K: Clone + Ord, V: Clone> IAssoc<K, V> for Standard<K, V>

Source§

type Output = Standard<K, V>

Source§

fn assoc(&self, k: K, v: V) -> Self

Source§

impl<K, V> IColl<(K, V)> for Standard<K, V>
where K: Clone + Ord + Hash + JavaHash + Debug, V: Clone + PartialEq + Hash + JavaHash + Debug,

Source§

fn start_string(&self) -> &'static str

Source§

fn end_string(&self) -> &'static str

Source§

fn separator(&self) -> &'static str

Source§

impl<K: Clone + Ord, V: Clone> IConj<(K, V)> for Standard<K, V>

Source§

type Output = Standard<K, V>

Source§

fn conj(&self, (k, v): (K, V)) -> Self

Source§

impl<K: Clone + Ord, V: Clone> ICount for Standard<K, V>

Source§

fn count(&self) -> usize

Source§

impl<K: Clone + Ord + Debug, V: Clone + Debug> IDisplay for Standard<K, V>

Source§

fn display(&self) -> String

Source§

impl<K: Clone + Ord, V: Clone> IDissoc<K> for Standard<K, V>

Source§

type Output = Standard<K, V>

Source§

fn dissoc(&self, k: &K) -> Self

Source§

impl<K: Clone + Ord, V: Clone> IEmpty for Standard<K, V>

Source§

type Output = Standard<K, V>

Source§

fn empty(&self) -> Self

Source§

impl<K: Clone + Ord, V: Clone + PartialEq> IEquality for Standard<K, V>

Source§

fn equality(&self, other: &Self) -> bool

Source§

impl<K: Clone + Ord, V: Clone> IFind<K> for Standard<K, V>

Source§

type Output = (K, V)

Source§

fn find(&self, k: &K) -> Option<Self::Output>

Source§

fn has(&self, key: &K) -> bool

Source§

impl<K: Clone + Ord + Hash + JavaHash, V: Clone + Hash + JavaHash> IHash for Standard<K, V>

Source§

fn hash_calc(&self, hash_type: HashType) -> u64

Source§

fn hash(&self) -> u64

Source§

fn hash_get(&self) -> u64

Source§

fn hash_get_as(&self, hash_type: HashType) -> u64

Source§

fn hash_type(&self) -> HashType

Source§

impl<K: Clone + Ord, V: Clone + PartialEq> IIndexedKV<K, V> for Standard<K, V>

Source§

fn index_of_key(&self, key: &K) -> Option<usize>

Source§

fn index_of_val(&self, value: &V) -> Option<usize>

Source§

impl<K: Clone + Ord, V: Clone> ILookup<K, V> for Standard<K, V>

Source§

type Keys = IntoIter<K>

Source§

type Values = IntoIter<V>

Source§

fn keys(&self) -> Self::Keys

Source§

fn vals(&self) -> Self::Values

Source§

fn lookup(&self, key: &K) -> Option<V>

Source§

fn lookup_or(&self, key: &K, not_found: V) -> V

Source§

impl<K: Clone + Ord, V: Clone> IMetadata for Standard<K, V>

Source§

type Metadata = Rc<Metadata>

Source§

fn meta(&self) -> Option<&Self::Metadata>

Source§

fn with_meta(&self, metadata: Option<Self::Metadata>) -> Self

Source§

fn metatype(&self) -> MetaType

Source§

impl<K: Clone + Ord, V: Clone> INth<Node<K, V>> for Standard<K, V>

Source§

fn nth(&self, index: usize) -> Option<&Node<K, V>>

Source§

impl<K: Clone + Ord + Debug, V: Clone + Debug> IObjType for Standard<K, V>

Source§

fn obj_type(&self) -> ObjType

Source§

fn obj_name(&self) -> &'static str

Source§

fn hash_seed(&self) -> String

Source§

impl<K: Clone + Ord, V: Clone> IPersistent for Standard<K, V>

Source§

impl<K: Clone + Ord, V: Clone> IToMutable for Standard<K, V>

Source§

type Mutable = Mutable<K, V>

Source§

fn to_mutable(&self) -> Self::Mutable

Source§

impl<K: Clone + Ord, V: Clone> IntoIterator for Standard<K, V>

Source§

type Item = (K, V)

The type of the elements being iterated over.
Source§

type IntoIter = IntoIter<(K, V)>

Which kind of iterator are we turning this into?
Source§

fn into_iter(self) -> Self::IntoIter

Creates an iterator from a value. Read more

Auto Trait Implementations§

§

impl<K, V> !RefUnwindSafe for Standard<K, V>

§

impl<K, V> !Send for Standard<K, V>

§

impl<K, V> !Sync for Standard<K, V>

§

impl<K, V> !UnwindSafe for Standard<K, V>

§

impl<K, V> Freeze for Standard<K, V>
where Link<K, V>: Freeze,

§

impl<K, V> Unpin for Standard<K, V>
where Link<K, V>: Unpin,

§

impl<K, V> UnsafeUnpin for Standard<K, V>
where Link<K, V>: UnsafeUnpin,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<S, T> Upcast<T> for S
where T: UpcastFrom<S> + ?Sized, S: ?Sized,

Source§

fn upcast(&self) -> &T
where Self: ErasableGeneric, T: Sized + ErasableGeneric<Repr = Self::Repr>,

Perform a zero-cost type-safe upcast to a wider ref type within the Wasm bindgen generics type system. Read more
Source§

fn upcast_into(self) -> T
where Self: Sized + ErasableGeneric, T: Sized + ErasableGeneric<Repr = Self::Repr>,

Perform a zero-cost type-safe upcast to a wider type within the Wasm bindgen generics type system. Read more