Class BaseDiscordClient
Inheritance
BaseDiscordClient
Implements
IDisposable
IAsyncDisposable
Assembly: Discord.Net.Rest.dll
Syntax
public abstract class BaseDiscordClient : object, IDiscordClient, IDisposable, IAsyncDisposable
Properties
|
Improve this Doc
View Source
CurrentUser
Declaration
public ISelfUser CurrentUser { get; protected set; }
Property Value
|
Improve this Doc
View Source
LoginState
Gets the login state of the client.
Declaration
public LoginState LoginState { get; }
Property Value
|
Improve this Doc
View Source
TokenType
Gets the token type of the logged-in user.
Declaration
public TokenType TokenType { get; }
Property Value
Methods
|
Improve this Doc
View Source
Dispose()
Declaration
|
Improve this Doc
View Source
DisposeAsync()
Declaration
public ValueTask DisposeAsync()
Returns
Type |
Description |
ValueTask |
|
|
Improve this Doc
View Source
GetBotGatewayAsync(RequestOptions)
Declaration
public Task<BotGateway> GetBotGatewayAsync(RequestOptions options = null)
Parameters
Returns
|
Improve this Doc
View Source
GetRecommendedShardCountAsync(RequestOptions)
Declaration
public Task<int> GetRecommendedShardCountAsync(RequestOptions options = null)
Parameters
Returns
Type |
Description |
Task<Int32> |
|
|
Improve this Doc
View Source
LoginAsync(TokenType, String, Boolean)
Declaration
public async Task LoginAsync(TokenType tokenType, string token, bool validateToken = true)
Parameters
Returns
|
Improve this Doc
View Source
LogoutAsync()
Declaration
public async Task LogoutAsync()
Returns
Events
|
Improve this Doc
View Source
Log
Declaration
public event Func<LogMessage, Task> Log
Event Type
|
Improve this Doc
View Source
LoggedIn
Declaration
public event Func<Task> LoggedIn
Event Type
Type |
Description |
Func<Task> |
|
|
Improve this Doc
View Source
LoggedOut
Declaration
public event Func<Task> LoggedOut
Event Type
Type |
Description |
Func<Task> |
|
Explicit Interface Implementations
|
Improve this Doc
View Source
IDiscordClient.ConnectionState
Gets the current state of connection.
Declaration
ConnectionState IDiscordClient.ConnectionState { get; }
Returns
|
Improve this Doc
View Source
IDiscordClient.CurrentUser
Gets the currently logged-in user.
Declaration
ISelfUser IDiscordClient.CurrentUser { get; }
Returns
Implements
IDisposable
IAsyncDisposable
Extension Methods