public List <Member> getMemberList(int mapid) { IDBUtil dBUtil = DBUtilFactory.getDBUtil("DBUtilImpl"); List <Member> m1 = dBUtil.getMemberList(mapid); return(m1); }
/*第二版*/ public void deleteMap(int mapid) { IDBUtil dBUtil = DBUtilFactory.getDBUtil("DBUtilImpl"); dBUtil.deleteMap(mapid); List <Member> list1 = dBUtil.getMemberList(mapid); for (int i = 0; i < list1.Count; i++) { List <Partner> list2 = dBUtil.getPartnerList(list1[i].Name); for (int j = 0; j < list2.Count; j++) { dBUtil.deletePartner(list2[j].Name); } dBUtil.deleteMember(list1[i].Name); } }