pub trait Mqtt {
fn send(&self, request: Request<'_>) -> Result<(), MqttError>;
fn client_id(&self) -> &str;
fn publish(
&self,
topic_name: &str,
payload: &[u8],
qos: QoS
) -> Result<(), MqttError> { ... }
fn subscribe(&self, topic: SubscribeTopic) -> Result<(), MqttError> { ... }
fn subscribe_many(
&self,
topics: Vec<SubscribeTopic, 5_usize>
) -> Result<(), MqttError> { ... }
fn unsubscribe(&self, topic: String<256_usize>) -> Result<(), MqttError> { ... }
fn unsubscribe_many(
&self,
topics: Vec<String<256_usize>, 5_usize>
) -> Result<(), MqttError> { ... }
}
impl<'a, 'b, 'c, const T: usize, const P: usize, const L: usize> Mqtt for Client<'a, 'b, T, P, L>