Пример #1
0
        public virtual async Task <TEntity> DeleteEntityAsync(TEntity entity)
        {
            ThrowIfDisposed();
            if (entity == null)
            {
                throw new ArgumentNullException("entity");
            }
            var deleted = EntityStore.Delete(entity);

            await this.SaveChangesAsync();

            return(deleted);
        }
 public async Task RemoveMajorAsync(Major major)
 {
     if (major == null)
     {
         throw new ArgumentNullException("major");
     }
     _majorStore.Delete(major);
     await SaveChanges();
 }
Пример #3
0
 public async Task DeleteTeacherInfo(TeacherInfo teacherInfo)
 {
     if (teacherInfo == null)
     {
         throw new ArgumentNullException("teacherInfo");
     }
     _teacherInfoStore.Delete(teacherInfo);
     await this.SaveChangesAsync();
 }
Пример #4
0
 public async Task DeleteStudentInfo(StudentInfo studentInfo)
 {
     if (studentInfo == null)
     {
         throw new ArgumentNullException("studentInfo");
     }
     _studentInfoStore.Delete(studentInfo);
     await this.SaveChangesAsync();
 }
Пример #5
0
 public LessonAsign DeleteLessonAsign(LessonAsign lessonAsign)
 {
     ThrowIfDisposed();
     if (lessonAsign == null)
     {
         throw new ArgumentNullException("lessonAsign");
     }
     return(_lessonAsignStore.Delete(lessonAsign));
 }
Пример #6
0
 public LessonInfo DeleteLessonInfo(LessonInfo lessonInfo)
 {
     ThrowIfDisposed();
     if (lessonInfo == null)
     {
         throw new ArgumentNullException("lessonInfo");
     }
     return(_lessonInfoStore.Delete(lessonInfo));
 }