public PhysicalAccessUtility(IEnumerable <Badge> inlab, string kioskIp, IKioskRepository repo) : this(inlab, Kiosks.Create(repo).IsOnKiosk(kioskIp)) { }
/// <summary> /// Checks if the kiosk ip begins with the ResourceIPPrefix (e.g. 192.168.1), or is a defined kiosk IP, or if Request.IsLocal is true. Does not check if user is in the lab. /// </summary> public bool IsKiosk() { bool result = Kiosks.Create(Provider.Scheduler.Kiosk).IsKiosk(Context.CurrentIP()) || Context.Request.IsLocal; return(result); }
public static bool IsKiosk(IKioskRepository repo, string userHostAddress) { return(Kiosks.Create(repo).IsKiosk(userHostAddress)); }