/// <summary> /// Removes the access rule. /// </summary> /// <param name="rule">The rule.</param> public virtual void RemoveAccessRule(AccessRuleBase rule) { if (_accessRules.Contains(rule)) { _accessRules.Remove(rule); rule.AccessRights = null; } }
/// <summary> /// Adds the access rule. /// </summary> /// <param name="rule">The rule.</param> public virtual void AddAccessRule(AccessRuleBase rule) { if (!_accessRules.Contains(rule)) { _accessRules.Add(rule); rule.AccessRights = this; } }