pub struct Guild {
pub id: String,
pub name: String,
pub tag: String,
pub emblem: GuildEmblem,
pub level: Option<u8>,
pub motd: Option<String>,
pub influence: Option<u64>,
pub aetherium: Option<u64>,
pub favor: Option<u64>,
pub member_count: Option<u16>,
pub member_capacity: Option<u16>,
}
Fields§
§id: String
§name: String
§tag: String
§emblem: GuildEmblem
§level: Option<u8>
§motd: Option<String>
§influence: Option<u64>
§aetherium: Option<u64>
§favor: Option<u64>
§member_count: Option<u16>
§member_capacity: Option<u16>
Implementations§
Source§impl Guild
impl Guild
Sourcepub fn get<C>(client: &C, id: &str) -> C::Resultwhere
C: ClientExecutor<Self>,
pub fn get<C>(client: &C, id: &str) -> C::Resultwhere
C: ClientExecutor<Self>,
Returns the guild with the given id
.
Sourcepub fn search<C>(client: &C, name: &str) -> C::Result
pub fn search<C>(client: &C, name: &str) -> C::Result
Returns a list of guild ids matching the searched name
. If no matches are found this
returns an empty Vec
.
§Examples
let client = Client::new();
let guilds = Guild::search(&client, "Covenant Of The Just").await?;
println!("{:?}", guilds);
Using the blocking
client:
let client = Client::new();
let guilds = Guild::search(&client, "Covenant Of The Just")?;
println!("{:?}", guilds);
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Guild
impl<'de> Deserialize<'de> for Guild
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Guild
impl RefUnwindSafe for Guild
impl Send for Guild
impl Sync for Guild
impl Unpin for Guild
impl UnwindSafe for Guild
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more