parser: Add helpers on MucUser
Signed-off-by: Maxime “pep” Buquet <pep@bouah.net>
This commit is contained in:
parent
9c39e3c195
commit
b8ba74e336
1 changed files with 19 additions and 0 deletions
|
@ -271,6 +271,25 @@ generate_element!(
|
|||
]
|
||||
);
|
||||
|
||||
impl MucUser {
|
||||
pub fn new() -> MucUser {
|
||||
MucUser {
|
||||
status: vec![],
|
||||
items: vec![],
|
||||
}
|
||||
}
|
||||
|
||||
pub fn with_status(mut self, status: Vec<Status>) -> MucUser {
|
||||
self.status = status;
|
||||
self
|
||||
}
|
||||
|
||||
pub fn with_items(mut self, items: Vec<Item>) -> MucUser {
|
||||
self.items = items;
|
||||
self
|
||||
}
|
||||
}
|
||||
|
||||
impl MessagePayload for MucUser {}
|
||||
impl PresencePayload for MucUser {}
|
||||
|
||||
|
|
Loading…
Reference in a new issue