package dst.ass2.service.api.courseplan.rest;

import javax.ws.rs.core.Response;

import dst.ass2.service.api.courseplan.CourseNotAvailableException;
import dst.ass2.service.api.courseplan.CoursePlan;
import dst.ass2.service.api.courseplan.EntityNotFoundException;

/**
 * The ICoursePlanResource exposes the {@code ICoursePlanService} as a RESTful interface.
 */
public interface ICoursePlanResource {

    // TODO annotate the class and methods with the correct javax.ws.rs annotations

    Response createCoursePlan(Long membershipId)
            throws EntityNotFoundException;

    Response deleteCoursePlan(Long coursePlanId)
            throws EntityNotFoundException;

    CoursePlan getCoursePlan(Long coursePlanId)
            throws EntityNotFoundException;

    Response addCourse(Long coursePlanId, Long courseId)
            throws EntityNotFoundException, CourseNotAvailableException;

    Response removeCourse(Long coursePlanId, Long courseId)
            throws EntityNotFoundException;

    Response submitCoursePlan(Long coursePlanId)
            throws EntityNotFoundException, CourseNotAvailableException;

}
