pub struct SubjectExtension {
pub id: Option<String>,
pub subject_type: Option<SubjectType>,
pub roles: HashSet<String>,
pub permissions: HashSet<String>,
pub teams: HashSet<String>,
pub claims: HashMap<String, String>,
}Expand description
Authenticated subject identity.
Fields§
§id: Option<String>Subject identifier (e.g., JWT sub).
subject_type: Option<SubjectType>Subject type.
roles: HashSet<String>Assigned roles.
permissions: HashSet<String>Granted permissions.
teams: HashSet<String>Team memberships.
claims: HashMap<String, String>Raw claims (e.g., JWT claims).
Trait Implementations§
Source§impl Clone for SubjectExtension
impl Clone for SubjectExtension
Source§fn clone(&self) -> SubjectExtension
fn clone(&self) -> SubjectExtension
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 SubjectExtension
impl Debug for SubjectExtension
Source§impl Default for SubjectExtension
impl Default for SubjectExtension
Source§fn default() -> SubjectExtension
fn default() -> SubjectExtension
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for SubjectExtension
impl<'de> Deserialize<'de> for SubjectExtension
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for SubjectExtension
impl RefUnwindSafe for SubjectExtension
impl Send for SubjectExtension
impl Sync for SubjectExtension
impl Unpin for SubjectExtension
impl UnsafeUnpin for SubjectExtension
impl UnwindSafe for SubjectExtension
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