From f9d44195133fa6b9bfd006ae3e2cd3d13210679a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Maxime=20=E2=80=9Cpep=E2=80=9D=20Buquet?= Date: Wed, 7 Jun 2023 19:17:06 +0200 Subject: [PATCH] parsers: Document new MucUser helpers MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Maxime “pep” Buquet --- parsers/src/muc/user.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/parsers/src/muc/user.rs b/parsers/src/muc/user.rs index b32b2c47..d6657ba3 100644 --- a/parsers/src/muc/user.rs +++ b/parsers/src/muc/user.rs @@ -272,6 +272,7 @@ generate_element!( ); impl MucUser { + /// Creates an empty MucUser pub fn new() -> MucUser { MucUser { status: vec![], @@ -279,11 +280,13 @@ impl MucUser { } } + /// Set statuses for this MucUser pub fn with_statuses(mut self, status: Vec) -> MucUser { self.status = status; self } + /// Set items for this MucUser pub fn with_items(mut self, items: Vec) -> MucUser { self.items = items; self