SAS/CourseDAO.h

59 lines
1.3 KiB
C
Raw Normal View History

/*
*
*/
2022-07-03 18:22:02 +08:00
#ifndef COURSE_DAO_H
#define COURSE_DAO_H
#import "c:\\Program Files\\Common Files\\System\\ado\\msado15.dll" no_namespace rename("EOF", "EndOfFile")
#include<iostream>
#include<vector>
#include"Course.h"
2022-07-03 18:22:02 +08:00
/*
*
* @param connection
* @param course
*/
2022-07-03 18:22:02 +08:00
void addCourse(_ConnectionPtr connection, Course course);
/*
*
* @param connection
* @param id
*/
2022-07-03 18:22:02 +08:00
void deleteCourse(_ConnectionPtr connection, string id);
/*
*
* @param connection
* @param id
* @param name
*/
2022-07-03 18:22:02 +08:00
void updateCourseName(_ConnectionPtr connection, string id, string name);
/*
*
* @param connection
* @param id
* @return Course* course对象指针
*/
2022-07-04 00:31:52 +08:00
Course* getCourseById(_ConnectionPtr connection, string id);
/*
*
* @param connection
* @param name
* @return Course* course对象指针
*/
2022-07-04 00:31:52 +08:00
Course* getCourseByName(_ConnectionPtr connection, string name);
/*
*
* @param connection
* @return vector<Course>* Course对象为元素的vector数组指针
*/
2022-07-04 00:31:52 +08:00
std::vector<Course>* getAllCourse(_ConnectionPtr connection);
2022-07-03 18:22:02 +08:00
#endif // !COURSE_DAO_H