pub struct PatchParams {
pub dry_run: bool,
pub force: bool,
pub field_manager: Option<String>,
pub field_validation: Option<ValidationDirective>,
}
Available on crate feature
client
only.Expand description
Common query parameters for patch calls
Fields§
§dry_run: bool
Whether to run this as a dry run
force: bool
force Apply requests. Applicable only to Patch::Apply
.
field_manager: Option<String>
fieldManager is a name of the actor that is making changes. Required for Patch::Apply
optional for everything else.
field_validation: Option<ValidationDirective>
The server-side validation directive to use. Applicable only to Patch::Apply
.
Implementations§
Source§impl PatchParams
impl PatchParams
Sourcepub fn apply(manager: &str) -> PatchParams
pub fn apply(manager: &str) -> PatchParams
Construct PatchParams
for server-side apply
Sourcepub fn force(self) -> PatchParams
pub fn force(self) -> PatchParams
Force the result through on conflicts
NB: Force is a concept restricted to the server-side Patch::Apply
.
Sourcepub fn dry_run(self) -> PatchParams
pub fn dry_run(self) -> PatchParams
Perform a dryRun only
Sourcepub fn validation(self, vd: ValidationDirective) -> PatchParams
pub fn validation(self, vd: ValidationDirective) -> PatchParams
Set the validation directive for fieldValidation
during server-side apply.
Sourcepub fn validation_ignore(self) -> PatchParams
pub fn validation_ignore(self) -> PatchParams
Set the validation directive to Ignore
Sourcepub fn validation_warn(self) -> PatchParams
pub fn validation_warn(self) -> PatchParams
Set the validation directive to Warn
Sourcepub fn validation_strict(self) -> PatchParams
pub fn validation_strict(self) -> PatchParams
Set the validation directive to Strict
Trait Implementations§
Source§impl Clone for PatchParams
impl Clone for PatchParams
Source§fn clone(&self) -> PatchParams
fn clone(&self) -> PatchParams
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for PatchParams
impl Debug for PatchParams
Source§impl Default for PatchParams
impl Default for PatchParams
Source§fn default() -> PatchParams
fn default() -> PatchParams
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for PatchParams
impl RefUnwindSafe for PatchParams
impl Send for PatchParams
impl Sync for PatchParams
impl Unpin for PatchParams
impl UnwindSafe for PatchParams
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§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