pub struct Connect {Show 15 fields
pub clean_start: bool,
pub keep_alive: u16,
pub session_expiry_interval_secs: u32,
pub auth_method: Option<ByteString>,
pub auth_data: Option<Bytes>,
pub request_problem_info: bool,
pub request_response_info: bool,
pub receive_max: Option<NonZeroU16>,
pub topic_alias_max: u16,
pub user_properties: UserProperties,
pub max_packet_size: Option<NonZeroU32>,
pub last_will: Option<LastWill>,
pub client_id: ByteString,
pub username: Option<ByteString>,
pub password: Option<Bytes>,
}
Expand description
Connect packet content
Fields§
§clean_start: bool
the handling of the Session state.
keep_alive: u16
a time interval measured in seconds.
session_expiry_interval_secs: u32
§auth_method: Option<ByteString>
§auth_data: Option<Bytes>
§request_problem_info: bool
§request_response_info: bool
§receive_max: Option<NonZeroU16>
§topic_alias_max: u16
§user_properties: UserProperties
§max_packet_size: Option<NonZeroU32>
§last_will: Option<LastWill>
Will Message be stored on the Server and associated with the Network Connection.
client_id: ByteString
identifies the Client to the Server.
username: Option<ByteString>
username can be used by the Server for authentication and authorization.
password: Option<Bytes>
password can be used by the Server for authentication and authorization.
Implementations§
source§impl Connect
impl Connect
sourcepub fn client_id<T>(self, client_id: T) -> Selfwhere
ByteString: From<T>,
pub fn client_id<T>(self, client_id: T) -> Selfwhere
ByteString: From<T>,
Set client_id value
sourcepub fn receive_max(self, max: u16) -> Self
pub fn receive_max(self, max: u16) -> Self
Set receive_max value