[−][src]Struct spectacles_rest::GuildView
A view for interfacing with a Discord guild.
Methods
impl GuildView
[src]
pub fn modify(
&self,
opts: ModifyGuildOptions
) -> impl Future<Item = Guild, Error = Error>
[src]
&self,
opts: ModifyGuildOptions
) -> impl Future<Item = Guild, Error = Error>
Modifies the settings of this guild.
pub fn delete(&self) -> impl Future<Item = (), Error = Error>
[src]
Deletes this guild from Discord.
pub fn get_channels(&self) -> impl Future<Item = Vec<Channel>, Error = Error>
[src]
Fetches all channels in the current guild.
pub fn create_channel(
&self,
opts: CreateChannelOptions
) -> impl Future<Item = Channel, Error = Error>
[src]
&self,
opts: CreateChannelOptions
) -> impl Future<Item = Channel, Error = Error>
Creates a new channel in this guild.
pub fn modify_channel_positions(&self)
[src]
Modifies a set of channel positions in this guild.
pub fn get_webhooks(&self) -> impl Future<Item = Webhook, Error = Error>
[src]
Gets a list of webhooks that belong to this guild.
pub fn get_member(
&self,
id: &Snowflake
) -> impl Future<Item = GuildMember, Error = Error>
[src]
&self,
id: &Snowflake
) -> impl Future<Item = GuildMember, Error = Error>
Gets a guild member of the specified user id.
pub fn list_members(
&self,
opts: ListMembersOptions
) -> impl Future<Item = Vec<GuildMember>, Error = Error>
[src]
&self,
opts: ListMembersOptions
) -> impl Future<Item = Vec<GuildMember>, Error = Error>
Lists all guild members in the current guild.
pub fn add_member(
&self,
id: &Snowflake,
opts: AddMemberOptions
) -> impl Future<Item = GuildMember, Error = Error>
[src]
&self,
id: &Snowflake,
opts: AddMemberOptions
) -> impl Future<Item = GuildMember, Error = Error>
Adds a member to the guild, using an Oauth2 access token.
pub fn add_member_role(
&self,
member: &Snowflake,
role: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
member: &Snowflake,
role: &Snowflake
) -> impl Future<Item = (), Error = Error>
Adds a role to the specified guild member.
pub fn get_emojis(&self) -> impl Future<Item = Vec<Emoji>, Error = Error>
[src]
Gets a list of emojis in the guild.
pub fn get_emoji(
&self,
emoji: &Snowflake
) -> impl Future<Item = Emoji, Error = Error>
[src]
&self,
emoji: &Snowflake
) -> impl Future<Item = Emoji, Error = Error>
Gets a a single emoji by snowflake in the guild.
pub fn create_emoji(
&self,
opts: CreateEmojiOptions
) -> impl Future<Item = Emoji, Error = Error>
[src]
&self,
opts: CreateEmojiOptions
) -> impl Future<Item = Emoji, Error = Error>
Creates a new emoji in this guild, with the provided options.
pub fn modify_emoji(
&self,
id: &Snowflake,
opts: ModifyGuildEmbedOptions
) -> impl Future<Item = Emoji, Error = Error>
[src]
&self,
id: &Snowflake,
opts: ModifyGuildEmbedOptions
) -> impl Future<Item = Emoji, Error = Error>
Modifies the provided emoji with the given options.
pub fn delete_emoji(
&self,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
Deletes the provided emoji from the guild.
pub fn get_audit_log(
&self,
opts: GetAuditLogOptions
) -> impl Future<Item = GuildAuditLog, Error = Error>
[src]
&self,
opts: GetAuditLogOptions
) -> impl Future<Item = GuildAuditLog, Error = Error>
Fetches the audit log for this guild.
pub fn get_bans(&self) -> impl Future<Item = Vec<GuildBan>, Error = Error>
[src]
Gets a list of bans in the guild.
pub fn get_ban(
&self,
user: &Snowflake
) -> impl Future<Item = GuildBan, Error = Error>
[src]
&self,
user: &Snowflake
) -> impl Future<Item = GuildBan, Error = Error>
Gets a a single ban for the provided user in the guild.
pub fn remove_ban(
&self,
user: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
user: &Snowflake
) -> impl Future<Item = (), Error = Error>
Removes a ban for the provided user from the guild.
pub fn get_roles(&self) -> impl Future<Item = Vec<Role>, Error = Error>
[src]
Gets a collection of roles from the guild.
pub fn create_role(
&self,
opts: CreateRoleOptions
) -> impl Future<Item = Role, Error = Error>
[src]
&self,
opts: CreateRoleOptions
) -> impl Future<Item = Role, Error = Error>
Creates a role in the guild.
pub fn modify_role(
&self,
role: &Snowflake,
opts: ModifyRoleOptions
) -> impl Future<Item = Role, Error = Error>
[src]
&self,
role: &Snowflake,
opts: ModifyRoleOptions
) -> impl Future<Item = Role, Error = Error>
Modifies the provided role in the guild.
pub fn get_prune_count(
&self,
days: i32
) -> impl Future<Item = GuildPrune, Error = Error>
[src]
&self,
days: i32
) -> impl Future<Item = GuildPrune, Error = Error>
Gets the number of members who would be pruned in a prune operation.
pub fn prune_members(
&self,
days: i32,
compute: bool
) -> impl Future<Item = GuildPrune, Error = Error>
[src]
&self,
days: i32,
compute: bool
) -> impl Future<Item = GuildPrune, Error = Error>
Prunes guild members, according to the provided options.
pub fn get_voice_regions(
&self
) -> impl Future<Item = Vec<VoiceRegion>, Error = Error>
[src]
&self
) -> impl Future<Item = Vec<VoiceRegion>, Error = Error>
Gets a list of voice regions for the guild.
pub fn get_invites(&self) -> impl Future<Item = Vec<Invite>, Error = Error>
[src]
Gets a list of guild invites.
pub fn get_integrations(
&self
) -> impl Future<Item = Vec<GuildIntegration>, Error = Error>
[src]
&self
) -> impl Future<Item = Vec<GuildIntegration>, Error = Error>
Gets a list of guild integrations.
pub fn add_integration(
&self,
kind: &str,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
kind: &str,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
Attaches an integration from the current user to the guild.
pub fn modify_integration(
&self,
id: &Snowflake,
opts: ModifyGuildIntegrationOptions
) -> impl Future<Item = (), Error = Error>
[src]
&self,
id: &Snowflake,
opts: ModifyGuildIntegrationOptions
) -> impl Future<Item = (), Error = Error>
Modifies the behavior and settings of a guild integration.
pub fn delete_integration(
&self,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
Deletes a guild integration by the provided ID.
pub fn sync_integration(
&self,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
id: &Snowflake
) -> impl Future<Item = (), Error = Error>
Syncs guild integration by the provided ID.
pub fn get_embed(&self) -> impl Future<Item = GuildEmbed, Error = Error>
[src]
Gets the embed object of this guild.
pub fn modify_embed(
&self,
opts: ModifyGuildEmbedOptions
) -> impl Future<Item = GuildEmbed, Error = Error>
[src]
&self,
opts: ModifyGuildEmbedOptions
) -> impl Future<Item = GuildEmbed, Error = Error>
Modifies the current guild embed.
pub fn modify_role_positions(&self)
[src]
Modifies a set of role positions in the guild.
pub fn remove_member_role(
&self,
member: &Snowflake,
role: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
member: &Snowflake,
role: &Snowflake
) -> impl Future<Item = (), Error = Error>
Removes a role from the specified guild member.
pub fn modify_member(
&self,
id: &Snowflake,
opts: ModifyMemberOptions
) -> impl Future<Item = (), Error = Error>
[src]
&self,
id: &Snowflake,
opts: ModifyMemberOptions
) -> impl Future<Item = (), Error = Error>
Modifies a guild member in this guild.
pub fn remove_member(
&self,
member: &Snowflake
) -> impl Future<Item = (), Error = Error>
[src]
&self,
member: &Snowflake
) -> impl Future<Item = (), Error = Error>
Removes a guild member from the guild.
pub fn set_current_user_nick(
&self,
nick: &str
) -> impl Future<Item = String, Error = Error>
[src]
&self,
nick: &str
) -> impl Future<Item = String, Error = Error>
Sets the nickname of the current client user.
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Erased for T
impl<T, U> TryInto for T where
U: TryFrom<T>,
U: TryFrom<T>,