I want to correctly represent my POCO classes of Entity Framework in UML diagram. For instance, I have the following relationships :
public class SchoolGroup {
public int Id {get;set;}
public string GroupName {get;set;}
public Subject GroupSubject {get;set;}
public Teacher GroupTeacher {get;set;}
public ICollection<Student> AttendeeStudents {get;set;}
}
Here we see that School Group Entity contains of instances of Subject, Teacher and a collection of Students.
According to this post Difference between association, aggregation and composition :
Association - I have a relationship with an object. Foo uses Bar.
Composition - I own an object and I am responsible for its lifetime, when Foo dies, so does Bar.
Aggregation - I have an object which I've borrowed from someone else. When Foo dies, Bar may live on.
So, how should I represent my SchoolGroup in UML notation : will it be a composition or an aggregation?