Files
RobustToolbox/Robust.Shared/Network/IServerNetManager.cs
2022-04-02 16:24:04 +02:00

26 lines
861 B
C#

using System;
using System.Threading.Tasks;
namespace Robust.Shared.Network
{
/// <summary>
/// The server version of the INetManager.
/// </summary>
public interface IServerNetManager : INetManager
{
public delegate Task<NetApproval> NetApprovalDelegate(NetApprovalEventArgs eventArgs);
byte[]? CryptoPublicKey { get; }
AuthMode Auth { get; }
Func<string, Task<NetUserId?>>? AssignUserIdCallback { get; set; }
NetApprovalDelegate? HandleApprovalCallback { get; set; }
/// <summary>
/// Disconnects this channel from the remote peer.
/// </summary>
/// <param name="channel">NetChannel to disconnect.</param>
/// <param name="reason">Reason why it was disconnected.</param>
void DisconnectChannel(INetChannel channel, string reason);
}
}