]> git.somenet.org - pub/jan/dst18.git/blob - ass2-service/api/src/main/java/dst/ass2/service/api/courseplan/rest/ICoursePlanResource.java
Add template for assignment 2
[pub/jan/dst18.git] / ass2-service / api / src / main / java / dst / ass2 / service / api / courseplan / rest / ICoursePlanResource.java
1 package dst.ass2.service.api.courseplan.rest;
2
3 import javax.ws.rs.core.Response;
4
5 import dst.ass2.service.api.courseplan.CourseNotAvailableException;
6 import dst.ass2.service.api.courseplan.CoursePlan;
7 import dst.ass2.service.api.courseplan.EntityNotFoundException;
8
9 /**
10  * The ICoursePlanResource exposes the {@code ICoursePlanService} as a RESTful interface.
11  */
12 public interface ICoursePlanResource {
13
14     // TODO annotate the class and methods with the correct javax.ws.rs annotations
15
16     Response createCoursePlan(Long membershipId)
17             throws EntityNotFoundException;
18
19     Response deleteCoursePlan(Long coursePlanId)
20             throws EntityNotFoundException;
21
22     CoursePlan getCoursePlan(Long coursePlanId)
23             throws EntityNotFoundException;
24
25     Response addCourse(Long coursePlanId, Long courseId)
26             throws EntityNotFoundException, CourseNotAvailableException;
27
28     Response removeCourse(Long coursePlanId, Long courseId)
29             throws EntityNotFoundException;
30
31     Response submitCoursePlan(Long coursePlanId)
32             throws EntityNotFoundException, CourseNotAvailableException;
33
34 }