Struct etcd_client::PutOptions
source · pub struct PutOptions(/* private fields */);
Expand description
Options for Put
operation.
Implementations§
source§impl PutOptions
impl PutOptions
sourcepub const fn with_lease(self, lease: i64) -> Self
pub const fn with_lease(self, lease: i64) -> Self
Lease is the lease ID to associate with the key in the key-value store. A lease value of 0 indicates no lease.
sourcepub const fn with_prev_key(self) -> Self
pub const fn with_prev_key(self) -> Self
If prev_kv is set, etcd gets the previous key-value pair before changing it. The previous key-value pair will be returned in the put response.
sourcepub const fn with_ignore_value(self) -> Self
pub const fn with_ignore_value(self) -> Self
If ignore_value is set, etcd updates the key using its current value. Returns an error if the key does not exist.
sourcepub const fn with_ignore_lease(self) -> Self
pub const fn with_ignore_lease(self) -> Self
If ignore_lease is set, etcd updates the key using its current lease. Returns an error if the key does not exist.
Trait Implementations§
source§impl Clone for PutOptions
impl Clone for PutOptions
source§fn clone(&self) -> PutOptions
fn clone(&self) -> PutOptions
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 PutOptions
impl Debug for PutOptions
source§impl Default for PutOptions
impl Default for PutOptions
source§fn default() -> PutOptions
fn default() -> PutOptions
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for PutOptions
impl RefUnwindSafe for PutOptions
impl Send for PutOptions
impl Sync for PutOptions
impl Unpin for PutOptions
impl UnwindSafe for PutOptions
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§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T
in a tonic::Request