AspNet.Identity.MongoDB.MongoDBUtilities.GetRoleCollectionName C# (CSharp) Method

GetRoleCollectionName() public static method

public static GetRoleCollectionName ( ) : String
return String
		public static String GetRoleCollectionName() {
			if (String.IsNullOrWhiteSpace(roleCollectionName)) {
				roleCollectionName = MongoDBIdentitySettings.Settings != null ? MongoDBIdentitySettings.Settings.RoleCollectionName : "role";
			}
			return roleCollectionName;
		}

Usage Example

示例#1
0
 public UserStore(String connectionNameOrUrl)
 {
     this.database       = MongoDBUtilities.GetDatabase(connectionNameOrUrl);
     this.collection     = database.GetCollection <TUser>(MongoDBUtilities.GetUserCollectionName());
     this.roleCollection = database.GetCollection <IdentityRole>(MongoDBUtilities.GetRoleCollectionName());
     this.disposed       = false;
 }
All Usage Examples Of AspNet.Identity.MongoDB.MongoDBUtilities::GetRoleCollectionName