Subversion Repositories eFlore/Applications.cel

Rev

Rev 1332 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1332 Rev 2568
Line 1... Line 1...
1
package org.tela_botanica.client.modeles.objets;
1
package org.tela_botanica.client.modeles.objets;
Line 2... Line 2...
2
 
2
 
3
/**
3
/**
4
 * 
4
 * 
5
 * Classe representant un element du referentiel commune ou localite
5
 * Classe representant un element du referentiel de localites
6
 * 
6
 * 
Line 7... Line 7...
7
 */
7
 */
Line 8... Line -...
8
 
-
 
9
public class ReferentielCommune {
8
 
10
 
9
public class ReferentielLocalite {
11
 
10
 
12
	private String commune=null;
-
 
13
	private String departement=null;
-
 
14
	private String codeInsee=null;
-
 
15
	
-
 
Line 16... Line 11...
16
	
11
	private String localite = null;
17
	public ReferentielCommune() {
12
	private String codeLocalite = null;
18
	}
13
	private String codeInsee = null;	
19
 
14
 
20
	/**
15
	/**
Line 21... Line 16...
21
	 * @param commune
16
	 * @param localite
22
	 * @param departement
17
	 * @param code
23
	 */
18
	 */
24
	public ReferentielCommune(String commune, String code) {
19
	public ReferentielLocalite(String localite, String code) {
25
		
20
		
26
		this.commune = commune;
21
		this.localite = localite;
27
		if(code.length() == 5) {
22
		if(code.length() == 5) {
28
			codeInsee = code;
23
			codeInsee = code;
Line 29... Line 24...
29
			departement = code.substring(0,2);
24
			codeLocalite = code.substring(0,2);
30
		} else {
25
		} else {
31
			departement = code;
26
			codeLocalite = code;
Line 32... Line -...
32
		}
-
 
33
	}
27
		}
34
 
28
	}
35
	public String getCommune() {
29
 
Line 36... Line 30...
36
		return commune;
30
	public String getLocalite() {
37
	}
31
		return localite;
38
 
32
	}
39
 
-
 
40
	public String getDepartement() {
33
 
41
		return departement;
34
	public String getCodeLocalite() {