pub enum PatchOpV1 {
AddFact {
fact: FactV1,
},
UpdateFact {
id: String,
fact: FactV1,
},
RetractFact {
id: String,
},
AddRelation {
relation: RelationV1,
},
RemoveRelation {
relation: RelationV1,
},
AddGap {
text: String,
},
CloseGap {
text: String,
},
AddPage {
page: PageV1,
},
UpdatePage {
id: String,
page: PageV1,
},
RemovePage {
id: String,
},
}Expand description
One edit of a proposal patch.
Variants§
AddFact
UpdateFact
RetractFact
Also drops the fact’s relations and its items on pages (1.9); a page left without items goes too.
AddRelation
Fields
§
relation: RelationV1RemoveRelation
Fields
§
relation: RelationV1AddGap
CloseGap
AddPage
1.9.
UpdatePage
1.9: replaces the page with id (page.id must equal it).
RemovePage
1.9.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for PatchOpV1
impl<'de> Deserialize<'de> for PatchOpV1
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 Eq for PatchOpV1
impl StructuralPartialEq for PatchOpV1
Auto Trait Implementations§
impl Forget for PatchOpV1
impl Freeze for PatchOpV1where
*const u8 is !null: Freeze,
PhantomData<u8>: Freeze,
PhantomData<String>: Freeze,
PhantomData<CodeAnchorV1>: Freeze,
PhantomData<PageItemV1>: Freeze,
impl Move for PatchOpV1
impl RefUnwindSafe for PatchOpV1
impl Send for PatchOpV1where
RawVecInner: Send,
impl Sync for PatchOpV1where
RawVecInner: Sync,
impl Unpin for PatchOpV1
impl UnsafeUnpin for PatchOpV1where
*const u8 is !null: UnsafeUnpin,
PhantomData<u8>: UnsafeUnpin,
PhantomData<String>: UnsafeUnpin,
PhantomData<CodeAnchorV1>: UnsafeUnpin,
PhantomData<PageItemV1>: UnsafeUnpin,
impl UnwindSafe for PatchOpV1where
RawVecInner: UnwindSafe,
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