public void Initialize(UserInfo userInfo, BanInfo banInfo) { if (this.isLoaded == true) { throw new InvalidOperationException(); } this.userInfo = userInfo; this.banInfo = banInfo; this.isLoaded = true; this.OnUserInfoChanged(EventArgs.Empty); this.OnUserBanInfoChanged(EventArgs.Empty); }
protected void Unban(IAuthentication authentication) { this.banInfo = BanInfo.Empty; this.OnUserBanInfoChanged(EventArgs.Empty); }
protected void Ban(IAuthentication authentication, BanInfo banInfo) { this.banInfo = banInfo; this.OnUserBanInfoChanged(EventArgs.Empty); }