예제 #1
0
 internal void RemoveRole(S4IdentityRole role)
 {
     if (role == null)
     {
         throw new ArgumentNullException(nameof(role));
     }
     s4roles = _roles.Where(r => !r.Equals(role)).ToList();
 }
예제 #2
0
        internal void AddRole(S4IdentityRole role)
        {
            if (role == null)
            {
                throw new ArgumentNullException(nameof(role));
            }
            var has_role = _roles.Any(r => r.Equals(role));

            if (!has_role)
            {
                _roles.Add(role);
            }
        }
예제 #3
0
 public bool Equals(S4IdentityRole other)
 {
     return(s4_role_name == other.s4_role_name);
 }