| Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
| FilmTemporaryContext |
|
| 1.0;1 |
| 1 | package org.jtheque.films.persistence.od.temp; | |
| 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.context.TemporaryContext; | |
| 20 | ||
| 21 | import java.util.ArrayList; | |
| 22 | import java.util.Collection; | |
| 23 | import java.util.List; | |
| 24 | ||
| 25 | /** | |
| 26 | * Temporary context of film. | |
| 27 | * | |
| 28 | * @author Baptiste Wicht | |
| 29 | */ | |
| 30 | 0 | public final class FilmTemporaryContext extends TemporaryContext { |
| 31 | private int intNote; | |
| 32 | private int lending; | |
| 33 | private int type; | |
| 34 | private int language; | |
| 35 | private int realizer; | |
| 36 | private List<Integer> actors; | |
| 37 | private List<Integer> kinds; | |
| 38 | ||
| 39 | /** | |
| 40 | * Return the temporary note of the film. | |
| 41 | * | |
| 42 | * @return The temporary note. | |
| 43 | */ | |
| 44 | public int getIntNote() { | |
| 45 | 0 | return intNote; |
| 46 | } | |
| 47 | ||
| 48 | /** | |
| 49 | * Sets the temporary note. The temporary note is used while importation to link note and | |
| 50 | * film when there are not completely loaded. | |
| 51 | * | |
| 52 | * @param intNote The temporary note. | |
| 53 | */ | |
| 54 | public void setTemporaryIntNote(int intNote) { | |
| 55 | 0 | this.intNote = intNote; |
| 56 | 0 | } |
| 57 | ||
| 58 | /** | |
| 59 | * Return the temporary lending id. | |
| 60 | * | |
| 61 | * @return The temporary lending id. | |
| 62 | */ | |
| 63 | public int getLending() { | |
| 64 | 0 | return lending; |
| 65 | } | |
| 66 | ||
| 67 | /** | |
| 68 | * Sets the temporary lending id. | |
| 69 | * | |
| 70 | * @param lending the temporary lending id | |
| 71 | */ | |
| 72 | public void setLending(int lending) { | |
| 73 | 0 | this.lending = lending; |
| 74 | 0 | } |
| 75 | ||
| 76 | /** | |
| 77 | * Return the temporary actors ids. | |
| 78 | * | |
| 79 | * @return The temporary actors ids. | |
| 80 | */ | |
| 81 | public Collection<Integer> getActors() { | |
| 82 | 0 | return actors; |
| 83 | } | |
| 84 | ||
| 85 | /** | |
| 86 | * Sets the temporary actors ids. | |
| 87 | * | |
| 88 | * @param actors the temporary actors ids | |
| 89 | */ | |
| 90 | public void setActors(List<Integer> actors) { | |
| 91 | 0 | this.actors = new ArrayList<Integer>(actors); |
| 92 | 0 | } |
| 93 | ||
| 94 | /** | |
| 95 | * Return the kinds of the temporary context. | |
| 96 | * | |
| 97 | * @return A Collection containing all the kinds of the temporary context. | |
| 98 | */ | |
| 99 | public Collection<Integer> getKinds() { | |
| 100 | 0 | return kinds; |
| 101 | } | |
| 102 | ||
| 103 | /** | |
| 104 | * Set the kinds of the temporary context. | |
| 105 | * | |
| 106 | * @param kinds The kinds of the temporayry context. | |
| 107 | */ | |
| 108 | public void setKinds(List<Integer> kinds) { | |
| 109 | 0 | this.kinds = new ArrayList<Integer>(kinds); |
| 110 | 0 | } |
| 111 | ||
| 112 | /** | |
| 113 | * Return the temporary language id. | |
| 114 | * | |
| 115 | * @return The temporary language id. | |
| 116 | */ | |
| 117 | public int getLanguage() { | |
| 118 | 0 | return language; |
| 119 | } | |
| 120 | ||
| 121 | /** | |
| 122 | * Sets the temporary language id. | |
| 123 | * | |
| 124 | * @param language the temporary language id | |
| 125 | */ | |
| 126 | public void setLanguage(int language) { | |
| 127 | 0 | this.language = language; |
| 128 | 0 | } |
| 129 | ||
| 130 | /** | |
| 131 | * Return the temporary realizer id. | |
| 132 | * | |
| 133 | * @return The temporary realizer id. | |
| 134 | */ | |
| 135 | public int getRealizer() { | |
| 136 | 0 | return realizer; |
| 137 | } | |
| 138 | ||
| 139 | /** | |
| 140 | * Sets the temporary lending id. | |
| 141 | * | |
| 142 | * @param realizer the temporary lending id | |
| 143 | */ | |
| 144 | public void setRealizer(int realizer) { | |
| 145 | 0 | this.realizer = realizer; |
| 146 | 0 | } |
| 147 | ||
| 148 | /** | |
| 149 | * Return the temporary type id. | |
| 150 | * | |
| 151 | * @return The temporary type id. | |
| 152 | */ | |
| 153 | public int getType() { | |
| 154 | 0 | return type; |
| 155 | } | |
| 156 | ||
| 157 | /** | |
| 158 | * Sets the temporary type id. | |
| 159 | * | |
| 160 | * @param type the temporary type id | |
| 161 | */ | |
| 162 | public void setType(int type) { | |
| 163 | 0 | this.type = type; |
| 164 | 0 | } |
| 165 | } |