pub struct RestoreCode {
pub v: u8,
pub sid: String,
pub ek: Option<String>,
pub name: String,
pub provider: CloudHomeJoinInfo,
pub store_root: StoreRootRef,
pub founder_pubkey: String,
pub membership_floor: MembershipFloor,
pub authority: RestoreAuthority,
}Expand description
Everything needed to restore a store from cloud storage.
Debug is hand-written: the encryption keyring and signing keys are
secrets and print as <redacted> so {:?} in an error path
cannot leak key material.
Fields§
§v: u8Wire-format version.
sid: StringStore ID (UUID).
ek: Option<String>Encryption keyring, present only for an opaque home.
Its presence is the home’s storage mode: present ⇒ opaque (the restorer
builds CloudCipher::Encrypted + BlobPathScheme::Hashed); absent ⇒
browsable (CloudCipher::Plaintext + BlobPathScheme::Plain).
name: StringStore display name.
provider: CloudHomeJoinInfoCloud provider and its connection details. Shared with the invite code
(InviteCode::join_info) — one wire representation for both. A
CloudHomeJoinInfo::CloudKitShare is never valid here: restore
recovers your own zone, not one shared to you, so
[decode_restore_code] rejects it.
store_root: StoreRootRef§founder_pubkey: String§membership_floor: MembershipFloorThe exact membership state the restorer must observe: causal author heads for MergeConcurrent stores, or the exact global commit for Serial stores.
Trait Implementations§
Source§impl Clone for RestoreCode
impl Clone for RestoreCode
Source§fn clone(&self) -> RestoreCode
fn clone(&self) -> RestoreCode
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for RestoreCode
impl Debug for RestoreCode
Source§impl<'de> Deserialize<'de> for RestoreCode
impl<'de> Deserialize<'de> for RestoreCode
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<RestoreCode, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<RestoreCode, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Source§impl Serialize for RestoreCode
impl Serialize for RestoreCode
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Auto Trait Implementations§
impl Freeze for RestoreCode
impl RefUnwindSafe for RestoreCode
impl Send for RestoreCode
impl Sync for RestoreCode
impl Unpin for RestoreCode
impl UnsafeUnpin for RestoreCode
impl UnwindSafe for RestoreCode
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> 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