View Javadoc
1   package fr.ifremer.tutti.persistence.entities.referential;
2   
3   /*
4    * #%L
5    * Tutti :: Persistence
6    * $Id:$
7    * $HeadURL:$
8    * %%
9    * Copyright (C) 2012 - 2017 Ifremer
10   * %%
11   * This program is free software: you can redistribute it and/or modify
12   * it under the terms of the GNU General Public License as
13   * published by the Free Software Foundation, either version 3 of the
14   * License, or (at your option) any later version.
15   * 
16   * This program is distributed in the hope that it will be useful,
17   * but WITHOUT ANY WARRANTY; without even the implied warranty of
18   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19   * GNU General Public License for more details.
20   * 
21   * You should have received a copy of the GNU General Public
22   * License along with this program.  If not, see
23   * <http://www.gnu.org/licenses/gpl-3.0.html>.
24   * #L%
25   */
26  
27  import java.util.Collection;
28  import java.util.LinkedList;
29  import java.util.List;
30  import javax.annotation.Generated;
31  
32  @Generated(value = "org.nuiton.eugene.java.SimpleJavaBeanTransformer", date = "Fri Jan 06 18:31:47 CET 2017")
33  public abstract class AbstractCaracteristicBean extends TuttiReferentialEntityBean implements Caracteristic {
34  
35      private static final long serialVersionUID = 4121409802975928883L;
36  
37      protected String unit;
38  
39      protected String category;
40  
41      protected String parameterName;
42  
43      protected String methodName;
44  
45      protected String matrixName;
46  
47      protected String fractionName;
48  
49      protected Integer maximumNumberDecimals;
50  
51      protected Float precision;
52  
53      protected Integer signifFiguresNumber;
54  
55      protected boolean numericType;
56  
57      protected Float minValue;
58  
59      protected Float maxValue;
60  
61      protected List<CaracteristicQualitativeValue> qualitativeValue;
62  
63      protected CaracteristicType caracteristicType;
64  
65      @Override
66      public String getUnit() {
67          return unit;
68      }
69  
70      @Override
71      public void setUnit(String unit) {
72          this.unit = unit;
73      }
74  
75      @Override
76      public String getCategory() {
77          return category;
78      }
79  
80      @Override
81      public void setCategory(String category) {
82          this.category = category;
83      }
84  
85      @Override
86      public String getParameterName() {
87          return parameterName;
88      }
89  
90      @Override
91      public void setParameterName(String parameterName) {
92          this.parameterName = parameterName;
93      }
94  
95      @Override
96      public String getMethodName() {
97          return methodName;
98      }
99  
100     @Override
101     public void setMethodName(String methodName) {
102         this.methodName = methodName;
103     }
104 
105     @Override
106     public String getMatrixName() {
107         return matrixName;
108     }
109 
110     @Override
111     public void setMatrixName(String matrixName) {
112         this.matrixName = matrixName;
113     }
114 
115     @Override
116     public String getFractionName() {
117         return fractionName;
118     }
119 
120     @Override
121     public void setFractionName(String fractionName) {
122         this.fractionName = fractionName;
123     }
124 
125     @Override
126     public Integer getMaximumNumberDecimals() {
127         return maximumNumberDecimals;
128     }
129 
130     @Override
131     public void setMaximumNumberDecimals(Integer maximumNumberDecimals) {
132         this.maximumNumberDecimals = maximumNumberDecimals;
133     }
134 
135     @Override
136     public Float getPrecision() {
137         return precision;
138     }
139 
140     @Override
141     public void setPrecision(Float precision) {
142         this.precision = precision;
143     }
144 
145     @Override
146     public Integer getSignifFiguresNumber() {
147         return signifFiguresNumber;
148     }
149 
150     @Override
151     public void setSignifFiguresNumber(Integer signifFiguresNumber) {
152         this.signifFiguresNumber = signifFiguresNumber;
153     }
154 
155     @Override
156     public boolean isNumericType() {
157         return numericType;
158     }
159 
160     @Override
161     public void setNumericType(boolean numericType) {
162         this.numericType = numericType;
163     }
164 
165     @Override
166     public Float getMinValue() {
167         return minValue;
168     }
169 
170     @Override
171     public void setMinValue(Float minValue) {
172         this.minValue = minValue;
173     }
174 
175     @Override
176     public Float getMaxValue() {
177         return maxValue;
178     }
179 
180     @Override
181     public void setMaxValue(Float maxValue) {
182         this.maxValue = maxValue;
183     }
184 
185     @Override
186     public CaracteristicQualitativeValue getQualitativeValue(int index) {
187         CaracteristicQualitativeValue o = getChild(qualitativeValue, index);
188         return o;
189     }
190 
191     @Override
192     public boolean isQualitativeValueEmpty() {
193         return qualitativeValue == null || qualitativeValue.isEmpty();
194     }
195 
196     @Override
197     public int sizeQualitativeValue() {
198         return qualitativeValue == null ? 0 : qualitativeValue.size();
199     }
200 
201     @Override
202     public void addQualitativeValue(CaracteristicQualitativeValue qualitativeValue) {
203         getQualitativeValue().add(qualitativeValue);
204     }
205 
206     @Override
207     public void addAllQualitativeValue(Collection<CaracteristicQualitativeValue> qualitativeValue) {
208         getQualitativeValue().addAll(qualitativeValue);
209     }
210 
211     @Override
212     public boolean removeQualitativeValue(CaracteristicQualitativeValue qualitativeValue) {
213         boolean removed = getQualitativeValue().remove(qualitativeValue);
214         return removed;
215     }
216 
217     @Override
218     public boolean removeAllQualitativeValue(Collection<CaracteristicQualitativeValue> qualitativeValue) {
219         boolean  removed = getQualitativeValue().removeAll(qualitativeValue);
220         return removed;
221     }
222 
223     @Override
224     public boolean containsQualitativeValue(CaracteristicQualitativeValue qualitativeValue) {
225         boolean contains = getQualitativeValue().contains(qualitativeValue);
226         return contains;
227     }
228 
229     @Override
230     public boolean containsAllQualitativeValue(Collection<CaracteristicQualitativeValue> qualitativeValue) {
231         boolean  contains = getQualitativeValue().containsAll(qualitativeValue);
232         return contains;
233     }
234 
235     @Override
236     public List<CaracteristicQualitativeValue> getQualitativeValue() {
237     if (qualitativeValue == null) {
238         qualitativeValue = new LinkedList<CaracteristicQualitativeValue>();
239     }
240     return qualitativeValue;
241 }
242 
243     @Override
244     public void setQualitativeValue(List<CaracteristicQualitativeValue> qualitativeValue) {
245         this.qualitativeValue = qualitativeValue;
246     }
247 
248     @Override
249     public CaracteristicType getCaracteristicType() {
250         return caracteristicType;
251     }
252 
253     @Override
254     public void setCaracteristicType(CaracteristicType caracteristicType) {
255         this.caracteristicType = caracteristicType;
256     }
257 
258 } //AbstractCaracteristicBean