I am new in C# and ASP.NET MVC , I worked in VB.NET and windows apps for 3+ years but every thing seems unknown in those areas...
Can anyone guide me where to learn , what repository is .... and why people use below codes to make a repository:
I don't understand the [Table(Name = "Albums")] part ... what is does ?... can anyone help ... please...
I find those codes in that below link:
asp.net mvc - How to create a fake repository with a 1-to-many association for MVC - Stack Overflow
Can anyone guide me where to learn , what repository is .... and why people use below codes to make a repository:
C#:
[Table(Name = "Albums")]
public class Album
{
[Column(IsDbGenerated = true, IsPrimaryKey = true)]
public int AlbumID { get; set; }
[Column]
public string Title { get; set; }
private EntitySet<Track> _tracks;
[Association(Storage = "_tracks", ThisKey = "AlbumID", OtherKey = "AlbumID")]
public EntitySet<Track> Tracks
{
get { return _tracks; }
set { _tracks.Assign(value); }
}
}
I don't understand the [Table(Name = "Albums")] part ... what is does ?... can anyone help ... please...
I find those codes in that below link:
asp.net mvc - How to create a fake repository with a 1-to-many association for MVC - Stack Overflow