Interface ICanConnect<TKey>
Connects clients.
Namespace: Microsoft.XboxStudios.ClientManager
Assembly: ClientManager.Abstractions.dll
Syntax
public interface ICanConnect<TKey> where TKey : notnull
Type Parameters
Name | Description |
---|---|
TKey | The type of key to use. |
Methods
View SourceConnectAsync(IEnumerable<TKey>, CancellationOptions?)
Connects clients to a game instance.
Declaration
ValueTask ConnectAsync(IEnumerable<TKey> keys, CancellationOptions? co = null)
Parameters
Type | Name | Description |
---|---|---|
IEnumerable<TKey> | keys | The keys to use to fetch clients and attempt connections. |
CancellationOptions? | co | The Microsoft.XboxStudios.Bifrost.CancellationOptions. |
Returns
Type | Description |
---|---|
ValueTask | A Task that represents the asynchronous operation. |
ConnectAsync(TKey, CancellationOptions?)
Connects a client to a game instance.
Declaration
ValueTask<bool> ConnectAsync(TKey key, CancellationOptions? co = null)
Parameters
Type | Name | Description |
---|---|---|
TKey | key | The |
CancellationOptions? | co | The Microsoft.XboxStudios.Bifrost.CancellationOptions. |
Returns
Type | Description |
---|---|
ValueTask<bool> | A value indicating whether connection was successful or not. |