pub struct AuthSubject {
pub tenant: TenantId,
pub principal: PrincipalId,
}Expand description
用于授权的租户级主体。
Fields§
§tenant: TenantId租户标识符。
principal: PrincipalId主体标识符。
Implementations§
Source§impl AuthSubject
impl AuthSubject
Sourcepub fn new(tenant: TenantId, principal: PrincipalId) -> Self
pub fn new(tenant: TenantId, principal: PrincipalId) -> Self
创建授权主体。
Trait Implementations§
Source§impl Clone for AuthSubject
impl Clone for AuthSubject
Source§fn clone(&self) -> AuthSubject
fn clone(&self) -> AuthSubject
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 AuthSubject
impl Debug for AuthSubject
Source§impl Hash for AuthSubject
impl Hash for AuthSubject
Source§impl PartialEq for AuthSubject
impl PartialEq for AuthSubject
Source§fn eq(&self, other: &AuthSubject) -> bool
fn eq(&self, other: &AuthSubject) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for AuthSubject
impl StructuralPartialEq for AuthSubject
Auto Trait Implementations§
impl Freeze for AuthSubject
impl RefUnwindSafe for AuthSubject
impl Send for AuthSubject
impl Sync for AuthSubject
impl Unpin for AuthSubject
impl UnsafeUnpin for AuthSubject
impl UnwindSafe for AuthSubject
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