pub struct StorageInvitation { /* private fields */ }Expand description
Provider information carried inside coven’s encrypted invite code. Native share tokens admit the recipient; they never identify grants for revocation.
Implementations§
Source§impl StorageInvitation
impl StorageInvitation
Sourcepub fn for_account(location: StorageConfig) -> Result<Self, StorageError>
pub fn for_account(location: StorageConfig) -> Result<Self, StorageError>
An already granted account location, or Dropbox’s shared namespace to
mount. An S3 admin uses this after making the member’s key in the console.
CloudKit instead needs the share URL returned by grant_access.
This invitation as shared with account, which a Dropbox or OneDrive
invite code carries so the joining device can check the sign-in it
holds is that account’s (§13.2).
Sourcepub fn account(&self) -> Option<&SharedWith>
pub fn account(&self) -> Option<&SharedWith>
The account the folder was shared with, when the invitation records one.
Sourcepub fn location(&self) -> &StorageConfig
pub fn location(&self) -> &StorageConfig
Nonsecret location used to construct the joining account’s adapter.
Sourcepub fn encode(&self) -> Result<SecretBytes, StorageError>
pub fn encode(&self) -> Result<SecretBytes, StorageError>
Encode as the database records a granted invitation, with bytes erased on drop. An invite code packs it instead (format.md D13).
Sourcepub fn decode(bytes: &[u8]) -> Result<Self, StorageError>
pub fn decode(bytes: &[u8]) -> Result<Self, StorageError>
Decode and validate an invitation the database recorded.
Trait Implementations§
Source§impl Clone for StorageInvitation
impl Clone for StorageInvitation
Source§impl Debug for StorageInvitation
impl Debug for StorageInvitation
Source§impl<'de> Deserialize<'de> for StorageInvitation
impl<'de> Deserialize<'de> for StorageInvitation
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>,
Auto Trait Implementations§
impl Freeze for StorageInvitation
impl RefUnwindSafe for StorageInvitation
impl Send for StorageInvitation
impl Sync for StorageInvitation
impl Unpin for StorageInvitation
impl UnsafeUnpin for StorageInvitation
impl UnwindSafe for StorageInvitation
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T> ErasedDestructor for Twhere
T: 'static,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more