Ignore:
Timestamp:
02/04/22 23:22:13 (3 years ago)
Author:
Test <matonikolov77@…>
Branches:
main
Children:
5b447b0
Parents:
3ded84d
Message:

Added CRUD for movies,persons,discussion,replies,genres
Added ajaxcalls

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/main/java/com/wediscussmovies/project/service/MovieService.java

    r3ded84d re0ef1b1  
    11package com.wediscussmovies.project.service;
    22
    3 import com.wediscussmovies.project.model.*;
     3import com.wediscussmovies.project.ajaxmodels.Grade;
     4import com.wediscussmovies.project.model.Genre;
     5import com.wediscussmovies.project.model.Movie;
     6import com.wediscussmovies.project.model.Person;
     7import com.wediscussmovies.project.model.User;
    48
     9import java.sql.Date;
    510import java.util.List;
    6 import java.util.Optional;
    711
    812public interface MovieService {
    9     public List<Movie> listAll();
    10     public List<Movie> searchByTitle(String title);
    11     public Optional<Movie> findById(Integer id);
    12     public Movie save(Movie movie);
    13     public void deleteById(Integer id);
     13     List<Movie> listAll();
     14     List<Movie> listAllByType(Character type);
     15     List<Movie> listAllWithoutDirector();
     16     List<Movie> searchByTitle(String title);
     17     Movie findById(Integer id);
     18     Movie save(String title, String description, String imageUrl, Date airingDate,Double  rating,
     19                Integer directorId,List<Integer> actorIds,List<Integer> genreIds);
     20
     21     Movie edit(Integer movieId,String title, String description, String imageUrl, Date airingDate,Double  rating,
     22                Integer directorId,List<Integer> actorIds, List<Integer> genreIds);
     23
     24     List<Person> findAllActorsForMovie(Movie movie);
     25     List<Genre> findAllGenresForMovie(Movie movie);
     26
     27     void likeMovie(Integer movieId, Integer userId);
     28     void unlikeMovie(Integer movieId,Integer userId);
     29
     30     List<Movie> findLikedMoviesByUser(User user);
     31
     32     void deleteById(Integer id);
     33
     34     void addGradeMovie(Integer movieId, User user, Grade grade);
    1435}
Note: See TracChangeset for help on using the changeset viewer.