pub trait ZoneConfigExt {
// Required methods
fn new(id: String, max_cells: u32) -> Self;
fn with_min_cells(self, min_cells: u32) -> Self;
}Expand description
Extension trait for ZoneConfig helper methods
§Example
use peat_protocol::models::zone::{ZoneConfig, ZoneConfigExt};
let config = ZoneConfig::new("zone_north".to_string(), 10);
assert_eq!(config.max_cells, 10);
assert_eq!(config.min_cells, 2);Required Methods§
Sourcefn with_min_cells(self, min_cells: u32) -> Self
fn with_min_cells(self, min_cells: u32) -> Self
Create configuration with custom minimum cells
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.