package tvark.model;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

import tvark.old.Student;
import tvark.old.Subject;
import tvark.old.Teacher;

public class Lesson implements Serializable {

	private static final long serialVersionUID = -7778923930300138088L;

	private List<Student> mStudents = new ArrayList<Student>();
	
	private Subject mSubject;
	
	private Teacher mTeacher;
	
	private int mRoom;
	
	private int mDay;
	
	private int mLesson;
	
	public Lesson(int pDay, int pLesson, Subject pSubject, Teacher pTeacher, List<Student> pStudents, int pRoom) {
		mStudents = pStudents;
		mSubject = pSubject;
		mTeacher = pTeacher;	
		mRoom = pRoom;
		mDay = pDay;
		mLesson = pLesson;
	}
	
	public List<Student> getStudents() {
		return mStudents;
	}
	
	public Subject getSubject() {
		return mSubject;
	}
	
	public Teacher getTeacher() {
		return mTeacher;
	}
	
	public String getGroup() {
		Student first = mStudents.iterator().next();
		return first != null ? first.getKlass() : null;
	}
	
	public int getRoom() 
	{
		return mRoom;
	}
	
	public int getDay() 
	{
		return mDay;
	}
	
	public int getLesson() 
	{
		return mLesson;
	}

}
