Class SocketChannel
Represents a WebSocket-based channel.
public abstract class SocketChannel : SocketEntity<ulong>, IChannel, IEntity<ulong>, IUpdateable
- Inheritance
-
SocketChannel
- Implements
- Derived
- Inherited Members
- Extension Methods
Properties
Users
Gets a collection of users from the WebSocket cache.
public IReadOnlyCollection<SocketUser> Users { get; }
Property Value
Methods
GetUser(ulong)
Gets a generic user from this channel.
public SocketUser? GetUser(ulong id)
Parameters
id
ulongThe identifier of the user.
Returns
- SocketUser
A generic WebSocket-based user associated with the identifier.
UpdateAsync(RequestOptions?)
Updates this object's properties with its current state.
public abstract Task UpdateAsync(RequestOptions? options = null)
Parameters
options
RequestOptionsThe options to be used when sending the request.
Returns
- Task
A task that represents an asynchronous reloading operation.
Remarks
warning
This method will fetch the latest data from REST API, and replace the current object's properties with the new data.