pub struct PendingRotation(/* private fields */);Implementations§
Source§impl PendingRotation
impl PendingRotation
pub fn none() -> Self
pub fn mark_candidate( &self, generation: u64, mutation: ObjectHash, ) -> Result<(), RotationStateError>
pub fn mark_committed_mutation( &self, generation: u64, mutation: ObjectHash, ) -> Result<(), RotationStateError>
pub fn remove_candidate( &self, generation: u64, mutation: ObjectHash, ) -> Result<(), RotationStateError>
pub fn replace_candidate_mutation( &self, generation: u64, previous: ObjectHash, replacement: ObjectHash, ) -> Result<(), RotationStateError>
pub fn gate(&self) -> Option<RotationGate>
pub fn install_durable_gate(&self, gate: Option<RotationGate>)
Sourcepub fn check(&self, live_generation: Option<u64>) -> Result<(), RotationPending>
pub fn check(&self, live_generation: Option<u64>) -> Result<(), RotationPending>
Check the live generation against the committed generation, if one is pending. A plaintext home never rotates a store key (sharing, and hence removal, requires an encrypted home), so it is never blocked.
Sourcepub fn mark_committed(&self, generation: u64) -> Result<(), RotationStateError>
pub fn mark_committed(&self, generation: u64) -> Result<(), RotationStateError>
Record that the cloud has committed generation and this device has not
folded it into its live cipher. Forward-only: a generation not newer than
one already recorded leaves the recorded value untouched, so an older
rediscovery (e.g. a decoy wrap from a non-rotating owner) can never erase
a genuinely newer generation already known to be pending.
Sourcepub fn pending_generation(&self) -> Option<u64>
pub fn pending_generation(&self) -> Option<u64>
The recorded committed generation, if any is pending — for status reporting independent of a specific cipher snapshot.
Trait Implementations§
Source§impl CloudSyncRotationStateAccess for PendingRotation
impl CloudSyncRotationStateAccess for PendingRotation
fn mark_candidate( &self, generation: u64, mutation: ObjectHash, ) -> Result<(), RotationStateError>
fn mark_committed_mutation( &self, generation: u64, mutation: ObjectHash, ) -> Result<(), RotationStateError>
fn remove_candidate( &self, generation: u64, mutation: ObjectHash, ) -> Result<(), RotationStateError>
fn replace_candidate_mutation( &self, generation: u64, previous: ObjectHash, replacement: ObjectHash, ) -> Result<(), RotationStateError>
fn gate(&self) -> Option<RotationGate>
fn install_durable_gate(&self, gate: Option<RotationGate>)
fn check(&self, live_generation: Option<u64>) -> Result<(), RotationPending>
Auto Trait Implementations§
impl !Freeze for PendingRotation
impl RefUnwindSafe for PendingRotation
impl Send for PendingRotation
impl Sync for PendingRotation
impl Unpin for PendingRotation
impl UnsafeUnpin for PendingRotation
impl UnwindSafe for PendingRotation
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
§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>
Converts
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>
Converts
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 moreCreates a shared type from an unshared type.
§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere
T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.