Esempio n. 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();
 }
Esempio n. 3
0
 public async Task DeleteTeacherInfo(TeacherInfo teacherInfo)
 {
     if (teacherInfo == null)
     {
         throw new ArgumentNullException("teacherInfo");
     }
     _teacherInfoStore.Delete(teacherInfo);
     await this.SaveChangesAsync();
 }
Esempio n. 4
0
 public async Task DeleteStudentInfo(StudentInfo studentInfo)
 {
     if (studentInfo == null)
     {
         throw new ArgumentNullException("studentInfo");
     }
     _studentInfoStore.Delete(studentInfo);
     await this.SaveChangesAsync();
 }
Esempio n. 5
0
 public LessonAsign DeleteLessonAsign(LessonAsign lessonAsign)
 {
     ThrowIfDisposed();
     if (lessonAsign == null)
     {
         throw new ArgumentNullException("lessonAsign");
     }
     return(_lessonAsignStore.Delete(lessonAsign));
 }
Esempio n. 6
0
 public LessonInfo DeleteLessonInfo(LessonInfo lessonInfo)
 {
     ThrowIfDisposed();
     if (lessonInfo == null)
     {
         throw new ArgumentNullException("lessonInfo");
     }
     return(_lessonInfoStore.Delete(lessonInfo));
 }