diff --git a/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.dll b/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.dll index ad80e86..b8c17cf 100644 Binary files a/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.dll and b/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.dll differ diff --git a/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.xml b/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.xml index d913c2e..e7acb97 100644 --- a/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.xml +++ b/src/lib/netcoreapp2.0/AspNetCore.Identity.MongoDbCore.xml @@ -9,6 +9,20 @@ The extensions for an object that holds claims. + + + Creates a object from a + + The . + A . + + + + Creates a object from a + + A . + A . + Adds a claim to a claim holder, implementing . @@ -34,6 +48,44 @@ The claim you want to replace. Returns true if the claim is present, false otherwise. + + + Removes a from the . + + The holder of the claim. + The to remove. + True is the claim was successfully removed. + + + + Removes an IEnumerable of s from the . + + The holder of the claims. + The s to remove. + True is the claims were successfully removed. + + + + Contains extension methods to for adding mongoDb Identity. + + + + + Configures the MongoDb Identity store adapters for the types of TUser only from . + + The type representing a user. + The type of the primary key of the identity document. + The collection of service descriptors. + A configuration object of the AspNetCore.Identity.MongoDbCore package. + + + + Configures the MongoDb Identity store adapters for the types of TUser only inheriting from . + + The type representing a user. + The collection of service descriptors. + A configuration object of the AspNetCore.Identity.MongoDbCore package. + Validates the MongoDbSettings @@ -42,14 +94,24 @@ - Configures the MongoDb Identity store adapters for + Configures the MongoDb Identity store adapters for the types of TUser and TRole. + + The type representing a user. + The type representing a role. + The type of the primary key of the identity document. + The collection of service descriptors. + A configuration object of the AspNetCore.Identity.MongoDbCore package. + An object representing a MongoDb connection. + + + + A class holding global variables. + + + + + A random number generator. - - - - - - @@ -81,11 +143,151 @@ The name of the MongoDb database where the identity data will be stored. + + + The repository used in the MongoDb identity stores. + + + + + Drops a collections. + + The type of the document used to define the collection name. + + + + Drops a partitioned collection. + + The type of the document used to define the collection name. + The partition key of the collection. + + + + The MongoDb context. + + + + + The repository used in the MongoDb identity stores. + + + + + The constructor for requiring a connection string and a database name. + + The connection string. + The database name. + + + + The constructor for requiring a . + + A . + + + + Drops a collections. + + The type of the document used to define the collection name. + + + + Drops a partitioned collection. + + The type of the document used to define the collection name. + The partition key of the collection. + + + + The MongoDb context. + + The interface for an object that holds claims. + + + The claims the has. + + + + + A class representing the claims a can have. + + + + + The type of the claim. + + + + + The value of the claim. + + + + + The issuer of the claim. + + + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a role name. + + The name of the role. + + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a role name. + + The name of the role. + + + + A document representing an document. + + The type of the primary key. + + + + The constructor for a + + + + + The constructor for a , taking a role name. + + The name of the role. + + + + The constructor for a , taking a role name and a primary key value. + + The name of the role. + The value of the primary key + The version of the role schema @@ -96,26 +298,214 @@ The claims associated to the role + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a username. + + The name of the user. + + + + The constructor for a , taking a username and an email address. + + The name of the user. + The email address of the user. + + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a username. + + The name of the user. + + + + The constructor for a , taking a username and an email address. + + The name of the user. + The email address of the user. + + + + A document representing an document. + + The type of the primary key. + + + + The version of the schema do the document. + + + + + The date and time at which this user was created, in UTC. + + + + + The claims this user has. + + + + + The role Ids of the roles that this user has. + + + + + The list of s that this user has. + + + + + The list of s that this user has. + + + + + The constructor for a , taking a username and an email address. + + + + + The constructor for a , taking a username and an email address. + + The name of the user. + The email address of the user. + + + + The constructor for a , taking a username. + + The name of the user. + + + + Sets the version of the schema for the document. + + + + + + + Removes a role. + + The Id of the role you want to remove. + True if the removal was successful. + + + + Add a role to the user. + + The Id of the role you want to add. + True if the addition was successful. + + + + Adds a user login to the user. + + The you want to add. + True if the addition was successful. + + + + Checks if the user has the given . + + The we are looking for. + True if the user has the given . + + + + Removes a from the user. + + + + + + + + + + + + + + Sets the token to a new value. + + The token you want to set you want to set. + The value you want to set the token to. + Returns true if the token was successfully set. + + + + Gets a token given the login provider and the name. + + The value for the login provider. + The name of the token. + An if found, or null. + + + + Checks if a user has the given token. + + The token you are looking for. + True if the user has the given token + + + + Adds a token to the user. + + The type of the token. + The token you want to add. + True if the addition was successful. + + + + Removes a token from the user. + + The type of the token. + The token you want to remove. + True if the removal was successful. + + + + A class representing the tokens a can have. + + Gets or sets the LoginProvider this token is from. - + + + Gets or sets the name of the token. + + Gets or sets the token value. - - - Replaces a claim on a claim holder, implementing . - - The object holding claims. - The claim you want to replace. - The new claim you want to set. - Returns true if the claim was replaced. - Creates a new instance of a persistence store for roles. @@ -346,9 +736,9 @@ - Constructs a new instance of . + Constructs a new instance of . - The . + The . The . @@ -360,9 +750,9 @@ - Constructs a new instance of . + Constructs a new instance of . - The . + The . The . @@ -375,9 +765,9 @@ - Constructs a new instance of . + Constructs a new instance of . - The . + The . The . @@ -388,10 +778,8 @@ The type of the data context class used to access the store. The type of the primary key for a role. The type representing a claim. - The type representing a user role. The type representing a user external login. The type representing a user token. - The type representing a role claim. @@ -1436,9 +1824,9 @@ Adds an MongoDb implementation of identity information stores. - - - + The type representing a user. + The type representing a role. + The type of the primary key of the identity document. The instance this method extends. @@ -1447,9 +1835,9 @@ Adds an MongoDb implementation of identity information stores. - - - + The type representing a user. + The type representing a role. + The type of the primary key of the identity document. The instance this method extends. diff --git a/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.dll b/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.dll index a7de6d4..e3b0477 100644 Binary files a/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.dll and b/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.dll differ diff --git a/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.xml b/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.xml index d913c2e..e7acb97 100644 --- a/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.xml +++ b/src/lib/netstandard2.0/AspNetCore.Identity.MongoDbCore.xml @@ -9,6 +9,20 @@ The extensions for an object that holds claims. + + + Creates a object from a + + The . + A . + + + + Creates a object from a + + A . + A . + Adds a claim to a claim holder, implementing . @@ -34,6 +48,44 @@ The claim you want to replace. Returns true if the claim is present, false otherwise. + + + Removes a from the . + + The holder of the claim. + The to remove. + True is the claim was successfully removed. + + + + Removes an IEnumerable of s from the . + + The holder of the claims. + The s to remove. + True is the claims were successfully removed. + + + + Contains extension methods to for adding mongoDb Identity. + + + + + Configures the MongoDb Identity store adapters for the types of TUser only from . + + The type representing a user. + The type of the primary key of the identity document. + The collection of service descriptors. + A configuration object of the AspNetCore.Identity.MongoDbCore package. + + + + Configures the MongoDb Identity store adapters for the types of TUser only inheriting from . + + The type representing a user. + The collection of service descriptors. + A configuration object of the AspNetCore.Identity.MongoDbCore package. + Validates the MongoDbSettings @@ -42,14 +94,24 @@ - Configures the MongoDb Identity store adapters for + Configures the MongoDb Identity store adapters for the types of TUser and TRole. + + The type representing a user. + The type representing a role. + The type of the primary key of the identity document. + The collection of service descriptors. + A configuration object of the AspNetCore.Identity.MongoDbCore package. + An object representing a MongoDb connection. + + + + A class holding global variables. + + + + + A random number generator. - - - - - - @@ -81,11 +143,151 @@ The name of the MongoDb database where the identity data will be stored. + + + The repository used in the MongoDb identity stores. + + + + + Drops a collections. + + The type of the document used to define the collection name. + + + + Drops a partitioned collection. + + The type of the document used to define the collection name. + The partition key of the collection. + + + + The MongoDb context. + + + + + The repository used in the MongoDb identity stores. + + + + + The constructor for requiring a connection string and a database name. + + The connection string. + The database name. + + + + The constructor for requiring a . + + A . + + + + Drops a collections. + + The type of the document used to define the collection name. + + + + Drops a partitioned collection. + + The type of the document used to define the collection name. + The partition key of the collection. + + + + The MongoDb context. + + The interface for an object that holds claims. + + + The claims the has. + + + + + A class representing the claims a can have. + + + + + The type of the claim. + + + + + The value of the claim. + + + + + The issuer of the claim. + + + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a role name. + + The name of the role. + + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a role name. + + The name of the role. + + + + A document representing an document. + + The type of the primary key. + + + + The constructor for a + + + + + The constructor for a , taking a role name. + + The name of the role. + + + + The constructor for a , taking a role name and a primary key value. + + The name of the role. + The value of the primary key + The version of the role schema @@ -96,26 +298,214 @@ The claims associated to the role + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a username. + + The name of the user. + + + + The constructor for a , taking a username and an email address. + + The name of the user. + The email address of the user. + + + + A where TKey is a + + + + + The constructor for a + + + + + The constructor for a , taking a username. + + The name of the user. + + + + The constructor for a , taking a username and an email address. + + The name of the user. + The email address of the user. + + + + A document representing an document. + + The type of the primary key. + + + + The version of the schema do the document. + + + + + The date and time at which this user was created, in UTC. + + + + + The claims this user has. + + + + + The role Ids of the roles that this user has. + + + + + The list of s that this user has. + + + + + The list of s that this user has. + + + + + The constructor for a , taking a username and an email address. + + + + + The constructor for a , taking a username and an email address. + + The name of the user. + The email address of the user. + + + + The constructor for a , taking a username. + + The name of the user. + + + + Sets the version of the schema for the document. + + + + + + + Removes a role. + + The Id of the role you want to remove. + True if the removal was successful. + + + + Add a role to the user. + + The Id of the role you want to add. + True if the addition was successful. + + + + Adds a user login to the user. + + The you want to add. + True if the addition was successful. + + + + Checks if the user has the given . + + The we are looking for. + True if the user has the given . + + + + Removes a from the user. + + + + + + + + + + + + + + Sets the token to a new value. + + The token you want to set you want to set. + The value you want to set the token to. + Returns true if the token was successfully set. + + + + Gets a token given the login provider and the name. + + The value for the login provider. + The name of the token. + An if found, or null. + + + + Checks if a user has the given token. + + The token you are looking for. + True if the user has the given token + + + + Adds a token to the user. + + The type of the token. + The token you want to add. + True if the addition was successful. + + + + Removes a token from the user. + + The type of the token. + The token you want to remove. + True if the removal was successful. + + + + A class representing the tokens a can have. + + Gets or sets the LoginProvider this token is from. - + + + Gets or sets the name of the token. + + Gets or sets the token value. - - - Replaces a claim on a claim holder, implementing . - - The object holding claims. - The claim you want to replace. - The new claim you want to set. - Returns true if the claim was replaced. - Creates a new instance of a persistence store for roles. @@ -346,9 +736,9 @@ - Constructs a new instance of . + Constructs a new instance of . - The . + The . The . @@ -360,9 +750,9 @@ - Constructs a new instance of . + Constructs a new instance of . - The . + The . The . @@ -375,9 +765,9 @@ - Constructs a new instance of . + Constructs a new instance of . - The . + The . The . @@ -388,10 +778,8 @@ The type of the data context class used to access the store. The type of the primary key for a role. The type representing a claim. - The type representing a user role. The type representing a user external login. The type representing a user token. - The type representing a role claim. @@ -1436,9 +1824,9 @@ Adds an MongoDb implementation of identity information stores. - - - + The type representing a user. + The type representing a role. + The type of the primary key of the identity document. The instance this method extends. @@ -1447,9 +1835,9 @@ Adds an MongoDb implementation of identity information stores. - - - + The type representing a user. + The type representing a role. + The type of the primary key of the identity document. The instance this method extends. diff --git a/test/AspNetCore.Identity.MongoDbCore.IntegrationTests/AspNetCore.Identity.MongoDbCore.Test/UserStoreTest.cs b/test/AspNetCore.Identity.MongoDbCore.IntegrationTests/AspNetCore.Identity.MongoDbCore.Test/UserStoreTest.cs index 1d4f0f4..bb0f6ac 100644 --- a/test/AspNetCore.Identity.MongoDbCore.IntegrationTests/AspNetCore.Identity.MongoDbCore.Test/UserStoreTest.cs +++ b/test/AspNetCore.Identity.MongoDbCore.IntegrationTests/AspNetCore.Identity.MongoDbCore.Test/UserStoreTest.cs @@ -2,37 +2,18 @@ // Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information. using System; -using System.Linq; using System.Linq.Expressions; using System.Threading.Tasks; using Microsoft.AspNetCore.Identity.Test; using Microsoft.Extensions.DependencyInjection; using Xunit; using AspNetCore.Identity.MongoDbCore.Models; -using AspNetCore.Identity.MongoDbCore; -using MongoDB.Driver; using AspNetCore.Identity.MongoDbCore.IntegrationTests.Infrastructure; -using AspNetCore.Identity.MongoDbCore.Infrastructure; using MongoDbGenericRepository; using Microsoft.AspNetCore.Identity; namespace AspNetCore.Identity.MongoDbCore.Test { - - public class ApplicationDbContext : MongoIdentityDbContext - { - public ApplicationDbContext(string connectionString, string databaseName) : base(connectionString, databaseName) - { - } - } - - public sealed class Applicationcontext - { - public static ApplicationDbContext Instance = new ApplicationDbContext( - Container.MongoDbIdentityConfiguration.MongoDbSettings.ConnectionString, - Container.MongoDbIdentityConfiguration.MongoDbSettings.DatabaseName); - } - public class UserStoreTest : IdentitySpecificationTestBase, IClassFixture> { private readonly MongoDatabaseFixture _fixture;