#[non_exhaustive]pub enum UserFields {
Preserve,
Authored,
}Expand description
Who is authoritative for the user-authored [doiget] fields
(tags, collections, annotation) on a write.
A fetch never authors them: every DoigetExtension the orchestrator
builds hard-codes Vec::new() / None. Letting that win silently
discarded a user’s tags on any re-fetch, which is the loss ADR-0056
closed for oa_status / license and left open here.
The distinction has to be explicit rather than “is the incoming value
empty”, because doiget tag --remove and doiget annotate --clear
legitimately mean the empty value.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Preserve
The caller did not author them; keep whatever is on disk. Fetches.
Authored
The caller means exactly what it wrote, empty included. doiget tag,
doiget annotate, and their MCP equivalents.
Trait Implementations§
Source§impl Clone for UserFields
impl Clone for UserFields
Source§fn clone(&self) -> UserFields
fn clone(&self) -> UserFields
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for UserFields
Source§impl Debug for UserFields
impl Debug for UserFields
impl Eq for UserFields
Source§impl PartialEq for UserFields
impl PartialEq for UserFields
Source§fn eq(&self, other: &UserFields) -> bool
fn eq(&self, other: &UserFields) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for UserFields
Auto Trait Implementations§
impl Freeze for UserFields
impl RefUnwindSafe for UserFields
impl Send for UserFields
impl Sync for UserFields
impl Unpin for UserFields
impl UnsafeUnpin for UserFields
impl UnwindSafe for UserFields
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