macros: Remove use requirement on ns.

This commit is contained in:
Emmanuel Gil Peyrot 2018-05-14 16:30:28 +02:00
commit 93b018e5ac
41 changed files with 112 additions and 141 deletions

View file

@ -6,9 +6,7 @@
use jid::Jid;
use ns;
generate_elem_id!(Group, "group", ns::ROSTER);
generate_elem_id!(Group, "group", ROSTER);
generate_attribute!(Subscription, "subscription", {
None => "none",
@ -21,7 +19,7 @@ generate_attribute!(Subscription, "subscription", {
generate_element_with_children!(
/// Contact from the users contact list.
#[derive(PartialEq)]
Item, "item", ns::ROSTER,
Item, "item", ROSTER,
attributes: [
/// JID of this contact.
jid: Jid = "jid" => required,
@ -35,13 +33,13 @@ generate_element_with_children!(
children: [
/// Groups this contact is part of.
groups: Vec<Group> = ("group", ns::ROSTER) => Group
groups: Vec<Group> = ("group", ROSTER) => Group
]
);
generate_element_with_children!(
/// The contact list of the user.
Roster, "query", ns::ROSTER,
Roster, "query", ROSTER,
attributes: [
/// Version of the contact list.
///
@ -52,7 +50,7 @@ generate_element_with_children!(
],
children: [
/// List of the contacts of the user.
items: Vec<Item> = ("item", ns::ROSTER) => Item
items: Vec<Item> = ("item", ROSTER) => Item
]
);