title: How to extend User Identity with an IEnumerable/Collection property
body: <p>Similar to this question: <a href="https://stackoverflow.com/questions/28335353/how-to-extend-available-properties-of-user-identity">How to extend available properties of User.Identity</a></p>
  
  <p>When a user logs in I'd like to load the departments my user has an association with.  I'm guessing that I'd add a property to the <code>ApplicationUser</code> class like this:</p>
  
  <pre><code>public class ApplicationUser : IdentityUser&lt;Guid, GuidUserLogin, GuidUserRole, GuidUserClaim&gt;
      {
          public async Task&lt;ClaimsIdentity&gt; GenerateUserIdentityAsync(ApplicationUserManager manager)
          {
              // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType
              var userIdentity = await manager.CreateIdentityAsync(this, DefaultAuthenticationTypes.ApplicationCookie);
              return userIdentity;
          }
  
  
          public IEnumerable&lt;Department&gt; Departments { get; set; }
      }
  </code></pre>
  
  <p>My question is how/where would I populate the collection, and then how would I access the property later in my controllers.  From what I understand, claims would be OK for simple types - an Id for example - but can they be used with collections?  </p>
  
  <p>I'm assuming once I have this property loaded, I'd be able to query the collection without hitting the database each time I need this information about the user - which will be often.</p>
  
  <p>Any help appreciated.</p>