pub enum RepoWrite {
Create {
collection: String,
rkey: Option<String>,
value: Value,
},
Update {
collection: String,
rkey: String,
value: Value,
},
Delete {
collection: String,
rkey: String,
},
}Expand description
One operation in a com.atproto.repo.applyWrites batch.
A closed union, tagged by $type exactly as the lexicon spells the
variants. Closed means a $type that is none of the three is refused, and
serde’s internally tagged enum gives that for free: an unrecognised tag is
a deserialization failure and becomes a 400 naming the field.
Variants§
Create
Write a new record, minting a key when none is named.
Fields
Update
Replace the record at a key.
Delete
Remove the record at a key, or make sure it is gone.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for RepoWrite
impl<'de> Deserialize<'de> for RepoWrite
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>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for RepoWrite
Auto Trait Implementations§
impl Freeze for RepoWrite
impl RefUnwindSafe for RepoWrite
impl Send for RepoWrite
impl Sync for RepoWrite
impl Unpin for RepoWrite
impl UnsafeUnpin for RepoWrite
impl UnwindSafe for RepoWrite
Blanket Implementations§
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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
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>
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 more