pub struct PrincipalAttr {
pub key: String,
pub value: String,
}Expand description
A single named attribute carried by a Principal.
Both key and value are derived identity facts (never secrets), so they are safe to use in routing and to surface as trace attributes.
Fields§
§key: StringThe attribute name (e.g. "tenant").
value: StringThe attribute value (e.g. "acme").
Implementations§
Trait Implementations§
Source§impl Clone for PrincipalAttr
impl Clone for PrincipalAttr
Source§fn clone(&self) -> PrincipalAttr
fn clone(&self) -> PrincipalAttr
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 PrincipalAttr
impl Debug for PrincipalAttr
impl Eq for PrincipalAttr
Source§impl PartialEq for PrincipalAttr
impl PartialEq for PrincipalAttr
Source§fn eq(&self, other: &PrincipalAttr) -> bool
fn eq(&self, other: &PrincipalAttr) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for PrincipalAttr
Auto Trait Implementations§
impl Freeze for PrincipalAttr
impl RefUnwindSafe for PrincipalAttr
impl Send for PrincipalAttr
impl Sync for PrincipalAttr
impl Unpin for PrincipalAttr
impl UnsafeUnpin for PrincipalAttr
impl UnwindSafe for PrincipalAttr
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