pub struct SavedProfile { /* private fields */ }Expand description
A saved authorization profile and its ownership and revision evidence.
Implementations§
Source§impl SavedProfile
impl SavedProfile
Sourcepub fn new(
profile_id: ProfileId,
owner: UserId,
revision: ProfileRevision,
profile: AuthorizationProfile,
) -> SavedProfile
pub fn new( profile_id: ProfileId, owner: UserId, revision: ProfileRevision, profile: AuthorizationProfile, ) -> SavedProfile
Constructs a record through the compatibility path for an unnamed
creation, assigning DEFAULT_PROFILE_NAME.
Sourcepub fn new_named(
profile_id: ProfileId,
owner: UserId,
revision: ProfileRevision,
name: ProfileName,
profile: AuthorizationProfile,
) -> SavedProfile
pub fn new_named( profile_id: ProfileId, owner: UserId, revision: ProfileRevision, name: ProfileName, profile: AuthorizationProfile, ) -> SavedProfile
Constructs a record with an explicitly validated name.
Sourcepub const fn profile_id(&self) -> ProfileId
pub const fn profile_id(&self) -> ProfileId
Returns the stable identity of this saved profile.
Sourcepub const fn revision(&self) -> ProfileRevision
pub const fn revision(&self) -> ProfileRevision
Returns the revision evidence for this saved profile.
Sourcepub fn name(&self) -> &ProfileName
pub fn name(&self) -> &ProfileName
Borrows the saved profile’s exact display name.
Sourcepub fn profile(&self) -> &AuthorizationProfile
pub fn profile(&self) -> &AuthorizationProfile
Borrows the authorization-profile value.
Trait Implementations§
Source§impl Clone for SavedProfile
impl Clone for SavedProfile
Source§fn clone(&self) -> SavedProfile
fn clone(&self) -> SavedProfile
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 SavedProfile
impl Debug for SavedProfile
impl Eq for SavedProfile
Source§impl PartialEq for SavedProfile
impl PartialEq for SavedProfile
impl StructuralPartialEq for SavedProfile
Auto Trait Implementations§
impl Freeze for SavedProfile
impl RefUnwindSafe for SavedProfile
impl Send for SavedProfile
impl Sync for SavedProfile
impl Unpin for SavedProfile
impl UnsafeUnpin for SavedProfile
impl UnwindSafe for SavedProfile
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