wabbajack/Wabbajack.Networking.Http.Interfaces/ITokenProvider.cs

17 lines
389 B
C#
Raw Normal View History

2021-09-27 12:42:46 +00:00
using System.Threading.Tasks;
2021-10-23 16:51:17 +00:00
namespace Wabbajack.Networking.Http.Interfaces;
/// <summary>
/// Interface for services that need a auth token of some sort
/// </summary>
/// <typeparam name="T"></typeparam>
public interface ITokenProvider<T>
2021-09-27 12:42:46 +00:00
{
2021-10-23 16:51:17 +00:00
public ValueTask<T?> Get();
2021-09-27 12:42:46 +00:00
2021-10-23 16:51:17 +00:00
public ValueTask SetToken(T val);
public ValueTask<bool> Delete();
2022-01-01 23:28:57 +00:00
public bool HaveToken();
2021-09-27 12:42:46 +00:00
}