示例#1
0
 public override void RemoveUsersFromRoles(string[] usernames, string[] roleNames)
 {
     var rolesDAL = new RolesDAL();
     foreach (var username in usernames)
     {
         foreach (var roleName in roleNames)
         {
             rolesDAL.RemoveUserFromRole(username, roleName);
         }
     }
 }
示例#2
0
 public override void AddUsersToRoles(string[] usernames, string[] roleNames)
 {
     var rolesDAL = new RolesDAL();
     foreach (var username in usernames)
     {
         foreach (var roleName in roleNames)
         {
             rolesDAL.AddUserToRole(username, roleName);
         }
     }
 }
示例#3
0
 public override bool RoleExists(string roleName)
 {
     var rolesDal = new RolesDAL();
     return rolesDal.RoleExists(roleName);
 }
示例#4
0
 public override string[] GetUsersInRole(string roleName)
 {
     var rolesDAL = new RolesDAL();
     return rolesDAL.GetUsersInRole(roleName);
 }
示例#5
0
 public override string[] GetRolesForUser(string username)
 {
     var rolesDAL = new RolesDAL();
     return rolesDAL.GetRolesForUser(username);
 }
示例#6
0
 public override string[] GetAllRoles()
 {
     var rolesDAL = new RolesDAL();
     return rolesDAL.GetAllRoles();
 }
示例#7
0
 public override string[] FindUsersInRole(string roleName, string usernameToMatch)
 {
     var rolesDAL = new RolesDAL();
     return rolesDAL.FindUsersInRole(roleName, usernameToMatch);
 }
示例#8
0
 public override bool DeleteRole(string roleName, bool throwOnPopulatedRole)
 {
     var rolesDal = new RolesDAL();
     return rolesDal.DeleteRole(roleName, throwOnPopulatedRole);
 }
示例#9
0
 public override void CreateRole(string roleName)
 {
     var rolesDal = new RolesDAL();
     rolesDal.CreateRole(roleName);
 }