#[non_exhaustive]pub struct NodeConfig {
pub cpu_count: i32,
pub memory_size_mb: i32,
/* private fields */
}Expand description
Configuration for a Memcached Node.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.cpu_count: i32Required. Number of cpus per Memcached node.
memory_size_mb: i32Required. Memory size in MiB for each Memcached node.
Implementations§
Source§impl NodeConfig
impl NodeConfig
pub fn new() -> Self
Sourcepub fn set_cpu_count<T: Into<i32>>(self, v: T) -> Self
pub fn set_cpu_count<T: Into<i32>>(self, v: T) -> Self
Sets the value of cpu_count.
Sourcepub fn set_memory_size_mb<T: Into<i32>>(self, v: T) -> Self
pub fn set_memory_size_mb<T: Into<i32>>(self, v: T) -> Self
Sets the value of memory_size_mb.
Trait Implementations§
Source§impl Clone for NodeConfig
impl Clone for NodeConfig
Source§fn clone(&self) -> NodeConfig
fn clone(&self) -> NodeConfig
Returns a duplicate 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 NodeConfig
impl Debug for NodeConfig
Source§impl Default for NodeConfig
impl Default for NodeConfig
Source§fn default() -> NodeConfig
fn default() -> NodeConfig
Returns the “default value” for a type. Read more
Source§impl PartialEq for NodeConfig
impl PartialEq for NodeConfig
impl StructuralPartialEq for NodeConfig
Auto Trait Implementations§
impl Freeze for NodeConfig
impl RefUnwindSafe for NodeConfig
impl Send for NodeConfig
impl Sync for NodeConfig
impl Unpin for NodeConfig
impl UnwindSafe for NodeConfig
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