| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
| IDaoSagas |
|
| 1.0;1 |
| 1 | package org.jtheque.primary.dao.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.core.managers.persistence.able.JThequeDao; | |
| 20 | import org.jtheque.primary.od.able.Saga; | |
| 21 | ||
| 22 | import java.util.Collection; | |
| 23 | ||
| 24 | /** | |
| 25 | * A DAO for sagas specification. | |
| 26 | * | |
| 27 | * @author Baptiste Wicht | |
| 28 | */ | |
| 29 | public interface IDaoSagas extends JThequeDao { | |
| 30 | String TABLE = "T_SAGAS"; | |
| 31 | ||
| 32 | /** | |
| 33 | * Return all the sagas. | |
| 34 | * | |
| 35 | * @return A List containing all the sagas. | |
| 36 | */ | |
| 37 | Collection<Saga> getSagas(); | |
| 38 | ||
| 39 | /** | |
| 40 | * Return the saga with the specified ID. | |
| 41 | * | |
| 42 | * @param id The ID of the searched saga. | |
| 43 | * @return The saga. | |
| 44 | */ | |
| 45 | Saga getSaga(int id); | |
| 46 | ||
| 47 | /** | |
| 48 | * Save the saga. | |
| 49 | * | |
| 50 | * @param saga The saga to save. | |
| 51 | */ | |
| 52 | void save(Saga saga); | |
| 53 | ||
| 54 | /** | |
| 55 | * Create the saga. | |
| 56 | * | |
| 57 | * @param saga The saga to create. | |
| 58 | */ | |
| 59 | void create(Saga saga); | |
| 60 | ||
| 61 | /** | |
| 62 | * Delete the saga. | |
| 63 | * | |
| 64 | * @param saga The saga to delete. | |
| 65 | * @return true if the object is deleted else false. | |
| 66 | */ | |
| 67 | boolean delete(Saga saga); | |
| 68 | ||
| 69 | /** | |
| 70 | * Create a saga. | |
| 71 | * | |
| 72 | * @return The created saga. | |
| 73 | */ | |
| 74 | Saga createSaga(); | |
| 75 | } |