public bool DeleteStudent(StudentDTO student) { var index = _studentDatabase.FindIndex(p => p.Id == student.Id); if (index >= 0) { _studentDatabase[index].Status = false; return true; } return false; }
public bool UpdateStudent(StudentDTO student) { var index = _studentDatabase.FindIndex(p => p.Id == student.Id); if (index >= 0) { _studentDatabase[index] = student; return true; } return false; }
public void CreateStudent(StudentDTO student) { _studentDatabase.Add(student); }