pub struct AffordanceKey { /* private fields */ }Expand description
Canonical identifier for a scheme instance seeded against a specific (actor, affordance, bindings) triple.
Implementations§
Source§impl AffordanceKey
impl AffordanceKey
Sourcepub fn new(
actor: impl Into<String>,
affordance_name: impl Into<String>,
bindings: &HashMap<String, String>,
) -> Self
pub fn new( actor: impl Into<String>, affordance_name: impl Into<String>, bindings: &HashMap<String, String>, ) -> Self
Construct a key from raw parts. Bindings are normalised into
a BTreeMap to give the key a deterministic hash.
Sourcepub fn affordance_name(&self) -> &str
pub fn affordance_name(&self) -> &str
The affordance-name component of the key.
Trait Implementations§
Source§impl Clone for AffordanceKey
impl Clone for AffordanceKey
Source§fn clone(&self) -> AffordanceKey
fn clone(&self) -> AffordanceKey
Returns a duplicate 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 AffordanceKey
impl Debug for AffordanceKey
Source§impl Hash for AffordanceKey
impl Hash for AffordanceKey
Source§impl PartialEq for AffordanceKey
impl PartialEq for AffordanceKey
impl Eq for AffordanceKey
impl StructuralPartialEq for AffordanceKey
Auto Trait Implementations§
impl Freeze for AffordanceKey
impl RefUnwindSafe for AffordanceKey
impl Send for AffordanceKey
impl Sync for AffordanceKey
impl Unpin for AffordanceKey
impl UnsafeUnpin for AffordanceKey
impl UnwindSafe for AffordanceKey
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,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Checks if this value is equivalent to the given key. Read more
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.