Subversion Repositories eFlore/Applications.coel

Rev

Rev 1292 | Rev 1329 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1292 Rev 1319
1
package org.tela_botanica.client.modeles.structure;
1
package org.tela_botanica.client.modeles.structure;
2
 
2
 
3
import java.util.Date;
3
import java.util.Date;
4
import java.util.Iterator;
4
import java.util.Iterator;
5
import java.util.Set;
5
import java.util.Set;
6
 
6
 
7
import org.tela_botanica.client.modeles.aDonnee;
7
import org.tela_botanica.client.modeles.aDonnee;
8
import org.tela_botanica.client.modeles.personne.Personne;
8
import org.tela_botanica.client.modeles.personne.Personne;
9
import org.tela_botanica.client.util.UtilString;
9
import org.tela_botanica.client.util.UtilString;
10
 
10
 
11
import com.extjs.gxt.ui.client.data.BaseModelData;
11
import com.extjs.gxt.ui.client.data.BaseModelData;
12
import com.google.gwt.i18n.client.DateTimeFormat;
12
import com.google.gwt.i18n.client.DateTimeFormat;
13
import com.google.gwt.json.client.JSONObject;
13
import com.google.gwt.json.client.JSONObject;
14
 
14
 
15
public class Structure extends aDonnee {
15
public class Structure extends aDonnee {
16
	
16
	
17
	private static final long serialVersionUID = -5623886668593288218L;
17
	private static final long serialVersionUID = -5623886668593288218L;
18
 
18
 
19
	public static final String PREFIXE = "cs";
19
	public static final String PREFIXE = "cs";
20
	public static final String URL_SITE = "WEB";
20
	public static final String URL_SITE = "WEB";
21
	public static final String URL_LOGO = "LOGO";
21
	public static final String URL_LOGO = "LOGO";
22
	
22
	
23
	private BaseModelData urls = null;
23
	private BaseModelData urls = null;
24
	private StructureAPersonneListe personnel = null;
24
	private StructureAPersonneListe personnel = null;
25
	private StructureValorisation valorisation = null;
25
	private StructureValorisation valorisation = null;
26
	private StructureConservation conservation = null;
26
	private StructureConservation conservation = null;
27
	public static String[] champsObligatoires = {"cs_id_structure", "csc_id_structure", "csv_id_structure"};
27
	public static String[] champsObligatoires = {"cs_id_structure", "csc_id_structure", "csv_id_structure"};
28
	
28
	
29
	public Structure() {
29
	public Structure() {
30
		// Constructions du tableau des urls interne
30
		// Constructions du tableau des urls interne
31
		urls = new BaseModelData();
31
		urls = new BaseModelData();
32
	}
32
	}
33
	
33
	
34
	public Structure(JSONObject institution) {
34
	public Structure(JSONObject institution) {
35
		// Constructions du tableau des urls interne
35
		// Constructions du tableau des urls interne
36
		urls = new BaseModelData();
36
		urls = new BaseModelData();
37
 
37
 
38
		// l'objet JSON est une table de hachage
38
		// l'objet JSON est une table de hachage
39
		Set<String> im = institution.keySet();
39
		Set<String> im = institution.keySet();
40
 
40
 
41
		// Parcourt pour chaque clé
41
		// Parcourt pour chaque clé
42
		for (Iterator<String> it = im.iterator(); it.hasNext();) {
42
		for (Iterator<String> it = im.iterator(); it.hasNext();) {
43
			// Si elle est associée à une valeur, nous l'ajoutons
43
			// Si elle est associée à une valeur, nous l'ajoutons
44
			String cle = it.next();
44
			String cle = it.next();
45
			if (cle.startsWith(PREFIXE+"_")) {
45
			if (cle.startsWith(PREFIXE+"_")) {
46
				// Suppression de l'abréviation du champ. Inutile dans le contexte d'un objet
46
				// Suppression de l'abréviation du champ. Inutile dans le contexte d'un objet
47
				String cleObjet = cle.replaceFirst("^"+PREFIXE+"_", "");
47
				String cleObjet = cle.replaceFirst("^"+PREFIXE+"_", "");
48
				// Sinon, nous ajoutons la clé avec une valeur vide
48
				// Sinon, nous ajoutons la clé avec une valeur vide
49
				String valeur = "";
49
				String valeur = "";
50
				if (institution.get(cle).isString() != null) {
50
				if (institution.get(cle).isString() != null) {
51
					valeur = institution.get(cle).isString().stringValue();
51
					valeur = institution.get(cle).isString().stringValue();
52
				}
52
				}
53
				if (cleObjet.equals("truk_url")) {
53
				if (cleObjet.equals("truk_url")) {
54
					this.setUrl(valeur);
54
					this.setUrl(valeur);
55
				} else {
55
				} else {
56
					this.set(cleObjet, valeur);
56
					this.set(cleObjet, valeur);
57
				}
57
				}
58
			}
58
			}
59
		}
59
		}
60
	}
60
	}
61
	
61
	
62
	@Override
62
	@Override
63
	protected String getPrefixe() {
63
	protected String getPrefixe() {
64
		return PREFIXE;
64
		return PREFIXE;
65
	}
65
	}
66
	
66
	
67
	protected String[] getChampsObligatoires()	{
67
	protected String[] getChampsObligatoires()	{
68
		return champsObligatoires;
68
		return champsObligatoires;
69
	}
69
	}
70
	
70
	
71
	public String getId() {
71
	public String getId() {
72
		return renvoyerValeurCorrecte("id_structure");
72
		return renvoyerValeurCorrecte("id_structure");
73
	}
73
	}
74
	public void setId(String idStructure) {
74
	public void setId(String idStructure) {
75
		this.set("id_structure", idStructure);
75
		this.set("id_structure", idStructure);
76
	}
76
	}
77
	
77
	
78
	public String getIdProjet() {
78
	public String getIdProjet() {
79
		return renvoyerValeurCorrecte("ce_projet");
79
		return renvoyerValeurCorrecte("ce_projet");
80
	}
80
	}
81
	public void setIdProjet(String idProjet) {
81
	public void setIdProjet(String idProjet) {
82
		this.set("ce_projet", idProjet);
82
		this.set("ce_projet", idProjet);
83
	}
83
	}
84
	
84
	
85
	public String getIdMere() {
85
	public String getIdMere() {
86
		return renvoyerValeurCorrecte("ce_mere");
86
		return renvoyerValeurCorrecte("ce_mere");
87
	}
87
	}
88
	public void setIdMere(String idMere) {
88
	public void setIdMere(String idMere) {
89
		this.set("ce_mere", idMere);
89
		this.set("ce_mere", idMere);
90
	}
90
	}
91
	
91
	
92
	public String getGuid() {
92
	public String getGuid() {
93
		return renvoyerValeurCorrecte("guid");
93
		return renvoyerValeurCorrecte("guid");
94
	}
94
	}
95
	public void setGuid(String guid) {
95
	public void setGuid(String guid) {
96
		this.set("guid", guid);
96
		this.set("guid", guid);
97
	}
97
	}
98
	
98
	
99
	public String getIdAlternatif() {
99
	public String getIdAlternatif() {
100
		return renvoyerValeurCorrecte("truk_identifiant_alternatif");
100
		return renvoyerValeurCorrecte("truk_identifiant_alternatif");
101
	}
101
	}
102
	public void setIdAlternatif(String idAlter) {
102
	public void setIdAlternatif(String idAlter) {
103
		this.set("truk_identifiant_alternatif", idAlter);
103
		this.set("truk_identifiant_alternatif", idAlter);
104
	}
104
	}
105
	
105
	
106
	public String getNom() {
106
	public String getNom() {
107
		return renvoyerValeurCorrecte("nom");
107
		return renvoyerValeurCorrecte("nom");
108
	}
108
	}
109
	public void setNom(String nom) {
109
	public void setNom(String nom) {
110
		this.set("nom", nom);
110
		this.set("nom", nom);
111
	}
111
	}
112
	
112
	
113
	public String getNomAlternatif() {
113
	public String getNomAlternatif() {
114
		return renvoyerValeurCorrecte("truk_nom_alternatif");
114
		return renvoyerValeurCorrecte("truk_nom_alternatif");
115
	}
115
	}
116
	
116
	
117
	public String getDescription() {
117
	public String getDescription() {
118
		return renvoyerValeurCorrecte("description");
118
		return renvoyerValeurCorrecte("description");
119
	}
119
	}
120
	public void setDescription(String description) {
120
	public void setDescription(String description) {
121
		this.set("description", description);
121
		this.set("description", description);
122
	}
122
	}
123
	
123
	
124
	public String getType() {
124
	public String getType() {
125
		return renvoyerValeurCorrecte("ce_type");
125
		return renvoyerValeurCorrecte("ce_type");
126
	}
126
	}
127
	public void setType(String type) {
127
	public void setType(String type) {
128
		this.set("ce_type", type);
128
		this.set("ce_type", type);
129
	}
129
	}
130
	
130
	
131
	public String getTypePrive() {
131
	public String getTypePrive() {
132
		return renvoyerValeurCorrecte("ce_truk_type_prive");
132
		return renvoyerValeurCorrecte("ce_truk_type_prive");
133
	}
133
	}
134
	public void setTypePrive(String typePrive) {
134
	public void setTypePrive(String typePrive) {
135
		this.set("ce_truk_type_prive", typePrive);
135
		this.set("ce_truk_type_prive", typePrive);
136
	}
136
	}
137
	
137
	
138
	public String getTypePublic() {
138
	public String getTypePublic() {
139
		return renvoyerValeurCorrecte("ce_truk_type_public");
139
		return renvoyerValeurCorrecte("ce_truk_type_public");
140
	}
140
	}
141
	public void setTypePublic(String typePublic) {
141
	public void setTypePublic(String typePublic) {
142
		this.set("ce_truk_type_public", typePublic);
142
		this.set("ce_truk_type_public", typePublic);
143
	}
143
	}
144
	
144
	
145
	public String getAdresse() {
145
	public String getAdresse() {
146
		return (String) renvoyerValeurCorrecte("adresse_01");
146
		return (String) renvoyerValeurCorrecte("adresse_01");
147
	}
147
	}
148
	public void setAdresse(String adr) {
148
	public void setAdresse(String adr) {
149
		this.set("adresse_01", adr);
149
		this.set("adresse_01", adr);
150
	}
150
	}
151
	
151
	
152
	public String getAdresseComplement() {
152
	public String getAdresseComplement() {
153
		return renvoyerValeurCorrecte("adresse_02");
153
		return renvoyerValeurCorrecte("adresse_02");
154
	}
154
	}
155
	public void setAdresseComplement(String adr) {
155
	public void setAdresseComplement(String adr) {
156
		this.set("adresse_02", adr);
156
		this.set("adresse_02", adr);
157
	}
157
	}
158
 
158
 
159
	public String getDateFondationFormatMysql() {
159
	public String getDateFondationFormatMysql() {
160
		return renvoyerValeurCorrecte("date_fondation");
160
		return renvoyerValeurCorrecte("date_fondation");
161
	}
161
	}
162
	public String getDateFondationFormatLong() {
162
	public String getDateFondationFormatLong() {
163
		String dateFormatee = "";
163
		String dateFormatee = "";
164
		Date dateFondation = getDateFondation();
164
		Date dateFondation = getDateFondation();
165
		if (dateFondation != null) {
165
		if (dateFondation != null) {
166
			dateFormatee = DateTimeFormat.getLongDateFormat().format(dateFondation);
166
			dateFormatee = DateTimeFormat.getLongDateFormat().format(dateFondation);
167
		}
167
		}
168
		return dateFormatee;
168
		return dateFormatee;
169
	}
169
	}
170
	
170
	
171
	public String getAnneOuDateFondationFormatLong() {
171
	public String getAnneOuDateFondationFormatLong() {
172
		String dateFormatee = "";
172
		String dateFormatee = "";
173
		String dateFondation =  renvoyerValeurCorrecte("date_fondation");
173
		String dateFondation =  renvoyerValeurCorrecte("date_fondation");
174
		if (!dateFondation.equals(""))	{
174
		if (!dateFondation.equals(""))	{
175
			if (dateFondation.endsWith("00-00"))	{
175
			if (dateFondation.endsWith("00-00"))	{
176
			dateFormatee = dateFondation.substring(0, 4);
176
			dateFormatee = dateFondation.substring(0, 4);
177
			} else {
177
			} else {
178
				Date date = DateTimeFormat.getFormat("yyyy-MM-dd").parse(dateFondation);
178
				Date date = DateTimeFormat.getFormat("yyyy-MM-dd").parse(dateFondation);
179
				dateFormatee = DateTimeFormat.getLongDateFormat().format(date);
179
				dateFormatee = DateTimeFormat.getLongDateFormat().format(date);
180
			}
180
			}
181
		}
181
		}
182
		return dateFormatee;
182
		return dateFormatee;
183
	}
183
	}
184
	public Date getDateFondation() {
184
	public Date getDateFondation() {
185
		Date fondationDate = null;
185
		Date fondationDate = null;
186
		String fondationChaine = renvoyerValeurCorrecte("date_fondation");
186
		String fondationChaine = renvoyerValeurCorrecte("date_fondation");
187
		if (!fondationChaine.isEmpty() && !fondationChaine.equals("0000-00-00")) {
187
		if (!fondationChaine.isEmpty() && !fondationChaine.equals("0000-00-00")) {
188
			fondationDate = DateTimeFormat.getFormat("yyyy-MM-dd").parseStrict(fondationChaine);
188
			fondationDate = DateTimeFormat.getFormat("yyyy-MM-dd").parseStrict(fondationChaine);
189
		}
189
		}
190
		return fondationDate;
190
		return fondationDate;
191
	}
191
	}
192
	
192
	
193
	public String getAnneeOuDateFondation()	{
193
	public String getAnneeOuDateFondation()	{
194
		 String valeurDateFondation = get("date_fondation");
194
		 String valeurDateFondation = get("date_fondation");
195
		 if (!UtilString.isEmpty(valeurDateFondation) && valeurDateFondation.endsWith("00-00")) {
195
		 if (!UtilString.isEmpty(valeurDateFondation) && valeurDateFondation.endsWith("00-00")) {
196
			 valeurDateFondation = valeurDateFondation.substring(0, 4);
196
			 valeurDateFondation = valeurDateFondation.substring(0, 4);
197
		 } else if (UtilString.isEmpty(valeurDateFondation) && valeurDateFondation.equals("0000-00-00")) {
197
		 } else if (UtilString.isEmpty(valeurDateFondation) && valeurDateFondation.equals("0000-00-00")) {
198
			 valeurDateFondation  = "";
198
			 valeurDateFondation  = "";
199
		 }
199
		 }
200
		 return valeurDateFondation;
200
		 return valeurDateFondation;
201
	}
201
	}
202
	
202
	
203
	public void setDateFondation(Date dateFondation) {
203
	public void setDateFondation(Date dateFondation) {
204
		if (dateFondation != null) {
204
		if (dateFondation != null) {
205
			this.set("date_fondation", DateTimeFormat.getFormat("yyyy-MM-dd").format(dateFondation));
205
			this.set("date_fondation", DateTimeFormat.getFormat("yyyy-MM-dd").format(dateFondation));
206
		}
206
		}
207
	}
207
	}
208
	public void setDateFondation(String dateFondation) {
208
	public void setDateFondation(String dateFondation) {
209
		if (dateFondation != null) {
209
		if (dateFondation != null) {
210
			this.set("date_fondation", dateFondation);
210
			this.set("date_fondation", dateFondation);
211
		}
211
		}
212
	}
212
	}
213
		
213
		
214
	public String getCodePostal() {
214
	public String getCodePostal() {
215
		return renvoyerValeurCorrecte("code_postal");
215
		return renvoyerValeurCorrecte("code_postal");
216
	}
216
	}
217
	public void setCodePostal(String codePostal) {
217
	public void setCodePostal(String codePostal) {
218
		this.set("code_postal", codePostal);
218
		this.set("code_postal", codePostal);
219
	}
219
	}
220
	
220
	
221
	public String getVille() {
221
	public String getVille() {
222
		return renvoyerValeurCorrecte("ville");
222
		return renvoyerValeurCorrecte("ville");
223
	}
223
	}
224
	public void setVille(String ville) {
224
	public void setVille(String ville) {
225
		this.set("ville", ville);
225
		this.set("ville", ville);
226
	}
226
	}
227
	
227
	
228
	public String getRegion() {
228
	public String getRegion() {
229
		return getChaineDenormaliseUnique("ce_truk_region");
229
		return getChaineDenormaliseUnique("ce_truk_region");
230
	}
230
	}
-
 
231
	
231
	public void setRegion(String region) {
232
	public void setRegion(String region) {
232
		this.set("ce_truk_region", region);
233
		this.set("ce_truk_region", region);
233
	}
234
	}
234
	
235
	
235
	public String getPays() {
236
	public String getPays() {
236
		return getChaineDenormaliseUnique("ce_truk_pays");
237
		return getChaineDenormaliseUnique("ce_truk_pays");
237
	}
238
	}
238
	public void setPays(String pays) {
239
	public void setPays(String pays) {
239
		this.set("ce_truk_pays", pays);
240
		this.set("ce_truk_pays", pays);
240
	}
241
	}
241
	
242
	
242
	public String getLatitude() {
243
	public String getLatitude() {
243
		return renvoyerValeurCorrecte("latitude");
244
		return renvoyerValeurCorrecte("latitude");
244
	}
245
	}
245
	public void setLatitude(String latitude) {
246
	public void setLatitude(String latitude) {
246
		if (latitude != null)	{
247
		if (latitude != null)	{
247
			latitude = latitude.replace(".", ",");
248
			latitude = latitude.replace(".", ",");
248
		}
249
		}
249
		this.set("latitude", latitude);
250
		this.set("latitude", latitude);
250
	}
251
	}
251
 
252
 
252
	public String getLongitude() {
253
	public String getLongitude() {
253
		return renvoyerValeurCorrecte("longitude");
254
		return renvoyerValeurCorrecte("longitude");
254
	}
255
	}
255
	public void setLongitude(String longitude) {
256
	public void setLongitude(String longitude) {
256
		if (longitude != null)	{
257
		if (longitude != null)	{
257
			longitude = longitude.replace(".", ",");
258
			longitude = longitude.replace(".", ",");
258
		}
259
		}
259
		this.set("longitude", longitude);
260
		this.set("longitude", longitude);
260
	}
261
	}
261
	
262
	
262
	// TELEPHONE
263
	// TELEPHONE
263
	public String getTelephone() {
264
	public String getTelephone() {
264
		return renvoyerValeurCorrecte("truk_telephone");
265
		return renvoyerValeurCorrecte("truk_telephone");
265
	}
266
	}
266
	public void setTelephone(String tel) {
267
	public void setTelephone(String tel) {
267
		this.set("truk_telephone", tel);
268
		this.set("truk_telephone", tel);
268
	}	
269
	}	
269
 
270
 
270
	// TELEPHONE FIXE
271
	// TELEPHONE FIXE
271
	public String getTelephoneFixe() {
272
	public String getTelephoneFixe() {
272
		return getInfoDenormaliseParType(renvoyerValeurCorrecte("truk_telephone"), Personne.TELEPHONE_FIXE);
273
		return getInfoDenormaliseParType(renvoyerValeurCorrecte("truk_telephone"), Personne.TELEPHONE_FIXE);
273
	}
274
	}
274
	public void setTelephoneFixe(String fixe) {
275
	public void setTelephoneFixe(String fixe) {
275
		modifierChaineDenormaliseParType("truk_telephone", Personne.TELEPHONE_FIXE, fixe);
276
		modifierChaineDenormaliseParType("truk_telephone", Personne.TELEPHONE_FIXE, fixe);
276
	}
277
	}
277
	
278
	
278
	//TELEPHONE FAX
279
	//TELEPHONE FAX
279
	public String getFax() {
280
	public String getFax() {
280
		return getInfoDenormaliseParType(renvoyerValeurCorrecte("truk_telephone"), Personne.TELEPHONE_FAX);
281
		return getInfoDenormaliseParType(renvoyerValeurCorrecte("truk_telephone"), Personne.TELEPHONE_FAX);
281
	}
282
	}
282
	public void setFax(String fax) {
283
	public void setFax(String fax) {
283
		modifierChaineDenormaliseParType("truk_telephone", Personne.TELEPHONE_FAX, fax);
284
		modifierChaineDenormaliseParType("truk_telephone", Personne.TELEPHONE_FAX, fax);
284
	}
285
	}
285
 
286
 
286
	
287
	
287
	// COURRIEL
288
	// COURRIEL
288
	public String getCourriel() {
289
	public String getCourriel() {
289
		return renvoyerValeurCorrecte("courriel");
290
		return renvoyerValeurCorrecte("courriel");
290
	}
291
	}
291
	public void setCourriel(String courriel) {
292
	public void setCourriel(String courriel) {
292
		this.set("courriel", courriel);
293
		this.set("courriel", courriel);
293
	}
294
	}
294
	
295
	
295
	// URL
296
	// URL
296
	public String getUrl(String type) {
297
	public String getUrl(String type) {
297
		return urls.get(type);
298
		return urls.get(type);
298
	}
299
	}
299
	public String getUrl() {
300
	public String getUrl() {
300
		String urlsDenormalise = "";
301
		String urlsDenormalise = "";
301
		Set<String> proprietes = urls.getProperties().keySet();
302
		Set<String> proprietes = urls.getProperties().keySet();
302
		for (Iterator<String> it = proprietes.iterator(); it.hasNext();) {
303
		for (Iterator<String> it = proprietes.iterator(); it.hasNext();) {
303
			String cle = it.next();
304
			String cle = it.next();
304
			urlsDenormalise += cle+"##"+urls.get(cle)+";;";
305
			urlsDenormalise += cle+"##"+urls.get(cle)+";;";
305
		}
306
		}
306
		urlsDenormalise.replaceFirst(";;$", "");
307
		urlsDenormalise.replaceFirst(";;$", "");
307
		return urlsDenormalise;
308
		return urlsDenormalise;
308
	}
309
	}
309
	public void setUrl(String urlsDenormalise) {
310
	public void setUrl(String urlsDenormalise) {
310
		if (urlsDenormalise != null && !urlsDenormalise.equals("")) {
311
		if (urlsDenormalise != null && !urlsDenormalise.equals("")) {
311
			//GWT.log(urlsDenormalise, null);
312
			//GWT.log(urlsDenormalise, null);
312
			String[] tableauUrls = urlsDenormalise.split(";;");
313
			String[] tableauUrls = urlsDenormalise.split(";;");
313
			for (int i = 0; i < tableauUrls.length; i++) {
314
			for (int i = 0; i < tableauUrls.length; i++) {
314
				String url = tableauUrls[i];
315
				String url = tableauUrls[i];
315
				//GWT.log("\t"+url, null);
316
				//GWT.log("\t"+url, null);
316
				String[] tableauUrl = url.split("##");
317
				String[] tableauUrl = url.split("##");
317
				if (tableauUrl.length == 2) {
318
				if (tableauUrl.length == 2) {
318
					//GWT.log("\t\t"+tableauUrl[0]+"-"+tableauUrl[1], null);
319
					//GWT.log("\t\t"+tableauUrl[0]+"-"+tableauUrl[1], null);
319
					urls.set(tableauUrl[0], tableauUrl[1]);
320
					urls.set(tableauUrl[0], tableauUrl[1]);
320
				}
321
				}
321
			}
322
			}
322
		}
323
		}
323
	}
324
	}
324
	public void setUrl(String type, String url) {
325
	public void setUrl(String type, String url) {
325
		if (url != null) {
326
		if (url != null) {
326
			urls.set(type, url);
327
			urls.set(type, url);
327
		}
328
		}
328
	}
329
	}
329
	
330
	
330
	public int getNbrePersonne() {
331
	public int getNbrePersonne() {
331
		if (renvoyerValeurCorrecte("nbre_personne").equals("")) {
332
		if (renvoyerValeurCorrecte("nbre_personne").equals("")) {
332
			return 0;
333
			return 0;
333
		} else {
334
		} else {
334
			return Integer.parseInt(renvoyerValeurCorrecte("nbre_personne"));
335
			return Integer.parseInt(renvoyerValeurCorrecte("nbre_personne"));
335
		}
336
		}
336
	}
337
	}
337
	public void setNbrePersonne(int nbrePersonne) {
338
	public void setNbrePersonne(int nbrePersonne) {
338
		this.set("nbre_personne", Integer.toString(nbrePersonne));
339
		this.set("nbre_personne", Integer.toString(nbrePersonne));
339
	}
340
	}
340
	
341
	
341
	public String getConditionAcces() {
342
	public String getConditionAcces() {
342
		return renvoyerValeurCorrecte("condition_acces");
343
		return renvoyerValeurCorrecte("condition_acces");
343
	}
344
	}
344
	public void setConditionAcces(String acces) {
345
	public void setConditionAcces(String acces) {
345
		this.set("condition_acces", acces);
346
		this.set("condition_acces", acces);
346
	}
347
	}
347
 
348
 
348
	public String getConditionUsage() {
349
	public String getConditionUsage() {
349
		return renvoyerValeurCorrecte("condition_usage");
350
		return renvoyerValeurCorrecte("condition_usage");
350
	}
351
	}
351
	public void setConditionUsage(String usage) {
352
	public void setConditionUsage(String usage) {
352
		this.set("condition_usage", usage);
353
		this.set("condition_usage", usage);
353
	}
354
	}
354
	
355
	
355
	public StructureAPersonneListe getPersonnel() {
356
	public StructureAPersonneListe getPersonnel() {
356
		return personnel;
357
		return personnel;
357
	}
358
	}
358
	public void setPersonnel(StructureAPersonneListe personnelAStocker) {
359
	public void setPersonnel(StructureAPersonneListe personnelAStocker) {
359
		personnel = personnelAStocker;
360
		personnel = personnelAStocker;
360
	}
361
	}
361
	
362
	
362
	public StructureValorisation getValorisation() {
363
	public StructureValorisation getValorisation() {
363
		return valorisation;
364
		return valorisation;
364
	}
365
	}
365
	public void setValorisation(StructureValorisation valorisationAStocker) {
366
	public void setValorisation(StructureValorisation valorisationAStocker) {
366
		valorisation = valorisationAStocker;
367
		valorisation = valorisationAStocker;
367
	}
368
	}
368
	
369
	
369
	public StructureConservation getConservation() {
370
	public StructureConservation getConservation() {
370
		return conservation;
371
		return conservation;
371
	}
372
	}
372
	public void setConservation(StructureConservation conservationAStocker) {
373
	public void setConservation(StructureConservation conservationAStocker) {
373
		conservation = conservationAStocker;
374
		conservation = conservationAStocker;
374
	}
375
	}
375
	
376
	
376
	public String toString() {
377
	public String toString() {
377
		String sortie = "";
378
		String sortie = "";
378
		
379
		
379
		// Champs du BaseModelData
380
		// Champs du BaseModelData
380
		Set<String> proprietes = this.getProperties().keySet();
381
		Set<String> proprietes = this.getProperties().keySet();
381
		for (Iterator<String> it = proprietes.iterator(); it.hasNext();) {
382
		for (Iterator<String> it = proprietes.iterator(); it.hasNext();) {
382
			String cle = it.next();
383
			String cle = it.next();
383
			sortie += cle+" : "+this.get(cle)+"\n";
384
			sortie += cle+" : "+this.get(cle)+"\n";
384
		}
385
		}
385
		
386
		
386
		// Champs spéciaux
387
		// Champs spéciaux
387
		sortie += getUrl();
388
		sortie += getUrl();
388
		
389
		
389
		return sortie;
390
		return sortie;
390
	}
391
	}
391
	
392
	
392
}
393
}