use std::collections::HashMap;
#[derive(Debug, Clone, Default)]
pub struct ConnectOverCdpOptions {
pub headers: Option<HashMap<String, String>>,
pub slow_mo: Option<f64>,
pub timeout: Option<f64>,
}
impl ConnectOverCdpOptions {
pub fn new() -> Self {
Self::default()
}
pub fn headers(mut self, headers: HashMap<String, String>) -> Self {
self.headers = Some(headers);
self
}
pub fn slow_mo(mut self, slow_mo: f64) -> Self {
self.slow_mo = Some(slow_mo);
self
}
pub fn timeout(mut self, timeout: f64) -> Self {
self.timeout = Some(timeout);
self
}
}
#[derive(Debug, Clone, Default)]
pub struct ConnectOptions {
pub headers: Option<HashMap<String, String>>,
pub slow_mo: Option<f64>,
pub timeout: Option<f64>,
}
impl ConnectOptions {
pub fn new() -> Self {
Self::default()
}
pub fn headers(mut self, headers: HashMap<String, String>) -> Self {
self.headers = Some(headers);
self
}
pub fn slow_mo(mut self, slow_mo: f64) -> Self {
self.slow_mo = Some(slow_mo);
self
}
pub fn timeout(mut self, timeout: f64) -> Self {
self.timeout = Some(timeout);
self
}
}