pub struct MqttConfig {
pub enabled: bool,
pub port: u16,
pub host: String,
pub max_connections: usize,
pub max_packet_size: usize,
pub keep_alive_secs: u16,
pub fixtures_dir: Option<PathBuf>,
pub enable_retained_messages: bool,
pub max_retained_messages: usize,
}
Expand description
MQTT server configuration
Fields§
§enabled: bool
Enable MQTT server
port: u16
Server port
host: String
Host address
max_connections: usize
Maximum connections
max_packet_size: usize
Maximum packet size
keep_alive_secs: u16
Keep-alive timeout in seconds
fixtures_dir: Option<PathBuf>
Directory containing fixture files
enable_retained_messages: bool
Enable retained messages
max_retained_messages: usize
Maximum retained messages
Trait Implementations§
Source§impl Clone for MqttConfig
impl Clone for MqttConfig
Source§fn clone(&self) -> MqttConfig
fn clone(&self) -> MqttConfig
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 MqttConfig
impl Debug for MqttConfig
Source§impl Default for MqttConfig
impl Default for MqttConfig
Source§impl<'de> Deserialize<'de> for MqttConfigwhere
MqttConfig: Default,
impl<'de> Deserialize<'de> for MqttConfigwhere
MqttConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MqttConfig
impl RefUnwindSafe for MqttConfig
impl Send for MqttConfig
impl Sync for MqttConfig
impl Unpin for MqttConfig
impl UnwindSafe for MqttConfig
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