Created
May 31, 2011 12:26
-
-
Save paigecook/1000421 to your computer and use it in GitHub Desktop.
EF Serialization Entity
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Collections.ObjectModel; | |
using System.Collections.Generic; | |
namespace MyTest | |
{ | |
public class Person | |
{ | |
public Person() | |
{ | |
Tags = new Collection<Tag>(); | |
} | |
public int Id { get; set; } | |
public string FirstName { get; set; } | |
public string LastName { get; set; } | |
public ICollection<Tag> Tags { get; set; } | |
} | |
public class Tag | |
{ | |
public Tag() | |
{ | |
People = new Collection<Person>(); | |
} | |
public int Id { get; set; } | |
public string Name { get; set; } | |
public ICollection<Person> People { get; set; } | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment