예제 #1
0
 /// <summary>
 /// Ctor
 /// </summary>
 public IdentityStore(IdentityContext context)
 {
     if (context == null)
     {
         throw new ArgumentNullException("context");
     }
     _context       = context;
     Logins         = new UserLoginStore <UserLogin>(_context);
     Roles          = new RoleStore <Role, UserRole>(_context);
     Secrets        = new UserSecretStore <UserSecret>(_context);
     Tokens         = new TokenStore <Token>(_context);
     UserClaims     = new UserClaimStore <UserClaim>(_context);
     UserManagement = new UserManagementStore <UserManagement>(_context);
     Users          = new UserStore <User>(_context);
 }
예제 #2
0
 /// <summary>
 /// Ctor
 /// </summary>
 public IdentityStore(IdentityContext context)
 {
     if (context == null)
     {
         throw new ArgumentNullException("context");
     }
     _context = context;
     Logins = new UserLoginStore<UserLogin>(_context);
     Roles = new RoleStore<Role, UserRole>(_context);
     Secrets = new UserSecretStore<UserSecret>(_context);
     Tokens = new TokenStore<Token>(_context);
     UserClaims = new UserClaimStore<UserClaim>(_context);
     UserManagement = new UserManagementStore<UserManagement>(_context);
     Users = new UserStore<User>(_context);
 }
 public CustomIdentityStore(System.Data.Entity.DbContext context)
 {
     if (context == null)
     {
         throw new ArgumentNullException("context");
     }
     _context = context;
     Logins = new UserLoginStore<CustomUserLogin>(_context);
     Roles = new RoleStore<CustomRole, CustomUserRole>(_context);
     Secrets = new UserSecretStore<CustomUserSecret>(_context);
     Tokens = new TokenStore<CustomToken>(_context);
     UserClaims = new UserClaimStore<CustomUserClaim>(_context);
     UserManagement = new UserManagementStore<CustomUserManagement>(_context);
     Users = new UserStore<CustomUser>(_context);
 }
예제 #4
0
        protected UserManager <IdentityUser> GetUserClaimManager()
        {
            var store = new UserClaimStore <IdentityUser>(Users);

            return(new UserManager <IdentityUser>(store));
        }