pub struct DocumentCreate {
pub source: SourceName,
pub project: NativeId,
pub title: String,
pub id: Option<NativeId>,
pub body: Body,
pub labels: Vec<String>,
pub repositories: Vec<Repository>,
pub metadata: BTreeMap<MetadataKey, Value>,
pub assets: Vec<AssetPayload>,
}Expand description
One project document to create, or replace, in one source.
Fields§
§source: SourceNameThe configured source to write it in.
project: NativeIdThe project it is filed under, by that source’s own id.
title: StringIts title.
id: Option<NativeId>The id to write it under: a document the source already holds by this id is
replaced, and otherwise one is created under it where the source lets a caller name
what it creates. None creates one under an id derived from the title.
body: BodyIts content.
labels: Vec<String>The names of its labels.
repositories: Vec<Repository>The repositories it concerns.
metadata: BTreeMap<MetadataKey, Value>The caller’s own metadata keys.
assets: Vec<AssetPayload>The image assets it holds, each referenced by its content as ./<name> — exactly
these, so a document it replaces keeps none this does not name.
Trait Implementations§
Source§impl Clone for DocumentCreate
impl Clone for DocumentCreate
Source§impl Debug for DocumentCreate
impl Debug for DocumentCreate
Source§impl PartialEq for DocumentCreate
impl PartialEq for DocumentCreate
impl StructuralPartialEq for DocumentCreate
Auto Trait Implementations§
impl Freeze for DocumentCreate
impl RefUnwindSafe for DocumentCreate
impl Send for DocumentCreate
impl Sync for DocumentCreate
impl Unpin for DocumentCreate
impl UnsafeUnpin for DocumentCreate
impl UnwindSafe for DocumentCreate
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