示例#1
0
        public static void DeleteInstructor()
        {
            Container cntr = new Container(baseUri);

            Instructor instr = cntr.Instructors.Where(inst => inst.Id == 1).Single();

            cntr.DeleteObject(instr);
            cntr.SaveChanges();
        }
示例#2
0
        public static void DeleteStudent()
        {
            Container cntr = new Container(baseUri);

            Student std = cntr.Students.Where(st => st.Id == 1).Single();

            cntr.DeleteObject(std);
            cntr.SaveChanges();
        }
示例#3
0
        public static void DeleteClass()
        {
            Container cntr = new Container(baseUri);

            Class cls = cntr.Classes.Where(clss => clss.Id == 1).Single();

            cntr.DeleteObject(cls);
            cntr.SaveChanges();
        }