Files
Pilz/Pilz.Net/Api/ApiAuthCheckEventArgs.cs
2024-08-16 09:19:03 +02:00

23 lines
380 B
C#

namespace Pilz.Net.Api;
public class ApiAuthCheckEventArgs(string authKey) : EventArgs
{
private bool hasDenyed;
public string AuthKey { get; } = authKey;
public bool Valid { get; set; }
public void Deny()
{
Valid = false;
hasDenyed = true;
}
public void Permit()
{
if (!hasDenyed)
Valid = true;
}
}