From 65d4e4360eb88e3bc5cc8f0da6135e5ee997af6c Mon Sep 17 00:00:00 2001 From: Still Hsu <341464@gmail.com> Date: Sun, 6 May 2018 06:57:53 +0800 Subject: [PATCH] Add BaseSocketClient docs --- src/Discord.Net.WebSocket/BaseSocketClient.cs | 57 +++++++++++++------ 1 file changed, 41 insertions(+), 16 deletions(-) diff --git a/src/Discord.Net.WebSocket/BaseSocketClient.cs b/src/Discord.Net.WebSocket/BaseSocketClient.cs index 81e573e1d..7dec313cf 100644 --- a/src/Discord.Net.WebSocket/BaseSocketClient.cs +++ b/src/Discord.Net.WebSocket/BaseSocketClient.cs @@ -50,30 +50,48 @@ namespace Discord.WebSocket /// /// Gets a Discord application information for the logged-in user. /// + /// + /// This method reflects your application information you submitted when creating a Discord application via + /// the Developer Portal. + /// /// The options to be used when sending the request. /// - /// Application information. This reflects your application information you submitted when creating a - /// Discord application via the Developer Portal. + /// An awaitable containing the application information. /// public abstract Task GetApplicationInfoAsync(RequestOptions options = null); /// /// Gets a user who shares a mutual guild with logged-in user with the provided snowflake ID. /// /// The user snowflake ID. + /// + /// This method gets the user present in the WebSocket cache with the given condition. + /// + /// Sometimes a user may return because Discord does not send offline users in + /// large guilds (i.e. guild with 100+ members) actively. To download more users on startup, please + /// enable . + /// + /// /// - /// A user who shares a mutual guild with the logged-in user and who is also present in the WebSocket cache; - /// or when the user cannot be found. + /// A WebSocket-based generic user; when the user cannot be found. /// public abstract SocketUser GetUser(ulong id); /// - /// Gets a user who shares a mutual guild with the logged-in user with the provided username and discriminator value combo. + /// Gets a user who shares a mutual guild with the logged-in user with the provided username and + /// discriminator value combo. /// /// The name of the user. /// The discriminator value of the user. + /// + /// This method gets the user present in the WebSocket cache with the given condition. + /// + /// Sometimes a user may return because Discord does not send offline users in + /// large guilds (i.e. guild with 100+ members) actively. To download more users on startup, please + /// enable . + /// + /// /// - /// A user who shares a mutual guild with the logged-in user and who is also present in the WebSocket cache; - /// or when the user cannot be found. + /// A WebSocket-based generic user; when the user cannot be found. /// public abstract SocketUser GetUser(string username, string discriminator); /// @@ -81,8 +99,8 @@ namespace Discord.WebSocket /// /// The channel snowflake ID. /// - /// A generic channel object (voice, text, category, etc.); or when the channel - /// cannot be found. + /// A generic WebSocket-based channel object (voice, text, category, etc.); when the + /// channel cannot be found. /// public abstract SocketChannel GetChannel(ulong id); /// @@ -90,7 +108,7 @@ namespace Discord.WebSocket /// /// The guild snowflake ID. /// - /// A guild; or when the guild cannot be found. + /// A WebSocket-based guild; when the guild cannot be found. /// public abstract SocketGuild GetGuild(ulong id); /// @@ -98,7 +116,7 @@ namespace Discord.WebSocket /// /// The unique identifier of the voice region. /// - /// A voice region; or if none can be found. + /// A REST-based voice region; if none can be found. /// public abstract RestVoiceRegion GetVoiceRegion(string id); /// @@ -127,9 +145,14 @@ namespace Discord.WebSocket /// Sets the of the logged-in user. /// /// - /// This method sets the of the user. Please note that Rich Presence cannot be - /// set via this method or client. Rich Presence is strictly limited to RPC clients only. Furthermore, - /// Discord will only accept setting of name and the type of activity. + /// This method sets the of the user. + /// + /// Discord will only accept setting of name and the type of activity. + /// + /// + /// Rich Presence cannot be set via this method or client. Rich Presence is strictly limited to RPC + /// clients only. + /// /// /// The activty to be set. /// @@ -149,8 +172,10 @@ namespace Discord.WebSocket /// Creates a guild for the logged-in user who is in less than 10 active guilds. /// /// - /// This method creates a new guild on behalf of the logged-in user. Note that due to Discord's limitation, - /// this method will only work for users that are in less than 10 guilds. + /// This method creates a new guild on behalf of the logged-in user. + /// + /// Due to Discord's limitation, this method will only work for users that are in less than 10 guilds. + /// /// /// The name of the new guild. /// The voice region to create the guild with.