mirror of
https://gitlab.com/fabinfra/fabaccess/borepin.git
synced 2025-03-13 07:11:56 +01:00
55 lines
1.6 KiB
C#
55 lines
1.6 KiB
C#
using Borepin.Model;
|
|
using FabAccessAPI.Schema;
|
|
using System.Threading.Tasks;
|
|
|
|
namespace Borepin.Service.BFFH
|
|
{
|
|
public interface IBFFHService
|
|
{
|
|
/// <summary>
|
|
/// Connection BFFH Service is currently connected
|
|
/// </summary>
|
|
Connection ActiveConnection { get; }
|
|
|
|
/// <summary>
|
|
/// Connection is connected and authenticated
|
|
/// </summary>
|
|
bool IsAuthenticated { get; }
|
|
|
|
/// <summary>
|
|
/// Can Connection with Credetials get Authenticated
|
|
/// </summary>
|
|
/// <returns></returns>
|
|
bool CanAuthenticate();
|
|
|
|
/// <summary>
|
|
/// Connect to BFFH Instance
|
|
/// </summary>
|
|
/// <param name="connection">Connection with address</param>
|
|
Task Connect(Connection connection);
|
|
|
|
/// <summary>
|
|
/// Disconnect from BFFH Instance
|
|
/// </summary>
|
|
Task Disconnect();
|
|
|
|
|
|
/// <summary>
|
|
/// Authenticate with ActiveConnection
|
|
/// Load password from SecureStorage
|
|
/// </summary>
|
|
Task<bool> Authenticate();
|
|
|
|
/// <summary>
|
|
/// Authenticate with ActiveConnection and password
|
|
/// If authenticate is successfull, save password to SecureStorage
|
|
/// </summary>
|
|
/// <param name="connection">address + username</param>
|
|
Task<bool> Authenticate(Connection connection, string password);
|
|
|
|
Task<IMachineSystem> GetMachineSystemInterface();
|
|
Task<IUserSystem> GetUserSystemInterface();
|
|
Task<IPermissionSystem> GetPermissionSystemInterface();
|
|
}
|
|
}
|