FlexitimeTracker/DataCenter_Windows/WindowsDataCenter/Interfaces/User.cs
chris.watts90@outlook.com 440c1f44ce Added IRepository comments.
Changed oder of response codes.
changed HoursPerWeek to use float not int.
Changed AssociatedIdentifierCount to use count property on AssociatedIdentifiers instead of needing to populate separately.
Changed UserCount in UserList for the same reason.
Added Users list initialisation to prevent null ref exception.
overrode Equals and GetHashCode to allow use of List.Except method. (tests show without this, Except is useless).
2017-01-31 21:57:21 +00:00

23 lines
568 B
C#

using System.Collections.Generic;
namespace Interfaces
{
public class User
{
public User()
{
AssociatedIdentifiers = new List<Identifier>();
}
public int UserId { get; set; }
public string FirstName { get; set; }
public string LastName { get; set; }
public float HoursPerWeek { get; set; }
public int AssociatedIdentifierCount
{
get { return AssociatedIdentifiers.Count; }
}
public List<Identifier> AssociatedIdentifiers { get; set; }
}
}