Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
IFilmAutoService |
|
| 1.0;1 |
1 | package org.jtheque.films.services.able; | |
2 | ||
3 | /* | |
4 | * This file is part of JTheque. | |
5 | * | |
6 | * JTheque is free software: you can redistribute it and/or modify | |
7 | * it under the terms of the GNU General Public License as published by | |
8 | * the Free Software Foundation, either version 3 of the License. | |
9 | * | |
10 | * JTheque is distributed in the hope that it will be useful, | |
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
13 | * GNU General Public License for more details. | |
14 | * | |
15 | * You should have received a copy of the GNU General Public License | |
16 | * along with JTheque. If not, see <http://www.gnu.org/licenses/>. | |
17 | */ | |
18 | ||
19 | import org.jtheque.films.persistence.od.able.Film; | |
20 | import org.jtheque.films.services.impl.utils.EditArguments; | |
21 | import org.jtheque.films.services.impl.utils.web.FilmResult; | |
22 | import org.jtheque.films.utils.Constants.Site; | |
23 | ||
24 | import java.util.Collection; | |
25 | ||
26 | /** | |
27 | * A service for the automatic recuperation of data. | |
28 | * | |
29 | * @author Baptiste Wicht | |
30 | */ | |
31 | public interface IFilmAutoService { | |
32 | /** | |
33 | * Return the films we found in a site for a specific search. | |
34 | * | |
35 | * @param site The site to search in. | |
36 | * @param search The film search. | |
37 | * @return A List containing all the films found on the site for the search. | |
38 | */ | |
39 | Collection<FilmResult> getFilms(Site site, String search); | |
40 | ||
41 | /** | |
42 | * Modify a film using a film found in a site. | |
43 | * | |
44 | * @param filmResult The result to get the informations from. | |
45 | * @param film The film to edit. | |
46 | * @param args The arguments who describe the fields to edit. | |
47 | */ | |
48 | void modifyFilm(FilmResult filmResult, Film film, EditArguments args); | |
49 | ||
50 | /** | |
51 | * Fill a film with the information of the film result and return it. | |
52 | * | |
53 | * @param filmResult The fim result to get the information from. | |
54 | * @return A film filled with the information of the site. | |
55 | */ | |
56 | Film getFilm(FilmResult filmResult); | |
57 | } |