pub enum RefExpectationWire {
Unspecified = 0,
Any = 1,
Missing = 2,
Match = 3,
}Expand description
A CAS expectation as its wire number, aligned with
mkit.transport.v1.RefExpectation. The numbers are load-bearing and match
mkit.rpc.v1.ssh.RefExpectation and mkit.repo.v1.RefExpectation.
Variants§
Unspecified = 0
REF_EXPECTATION_UNSPECIFIED (0): a protocol error.
Any = 1
REF_EXPECTATION_ANY (1): last writer wins.
Missing = 2
REF_EXPECTATION_MISSING (2): create only.
Match = 3
REF_EXPECTATION_MATCH (3): the current value must equal the expected id.
Implementations§
Source§impl RefExpectationWire
impl RefExpectationWire
Sourcepub const fn from_wire(n: i32) -> Self
pub const fn from_wire(n: i32) -> Self
Map a raw enum wire number. Unknown numbers collapse to
Self::Unspecified, which is rejected downstream.
Trait Implementations§
Source§impl Clone for RefExpectationWire
impl Clone for RefExpectationWire
impl Copy for RefExpectationWire
Source§impl Debug for RefExpectationWire
impl Debug for RefExpectationWire
impl Eq for RefExpectationWire
Source§impl PartialEq for RefExpectationWire
impl PartialEq for RefExpectationWire
impl StructuralPartialEq for RefExpectationWire
Auto Trait Implementations§
impl Freeze for RefExpectationWire
impl RefUnwindSafe for RefExpectationWire
impl Send for RefExpectationWire
impl Sync for RefExpectationWire
impl Unpin for RefExpectationWire
impl UnsafeUnpin for RefExpectationWire
impl UnwindSafe for RefExpectationWire
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