Consider the following model:
public partial class Person
{
public int Id { get; set; }
public string Name { get; set; }
}
public partial class Teacher : Person
{
public string ClassName { get; set; }
}
public partial class Student : Person
{
public int NumberOfClasses { get; set; }
}
Using that model and Entity Framework, is it possible to have a "Student" instance and a "Teacher" instance both derived from the same base "Person" instance? In other words, can a "Person" be both a "Student" and a "Teacher"?
If so, what would be the best inheritance strategy to use to represent this scenario?