Subversion Repositories eFlore/Applications.cel

Rev

Rev 989 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

package org.tela_botanica.client.modeles.objets;

/**
 * 
 * Classe representant un element du referentiel commune ou localite
 * 
 */

public class ReferentielCommune {


        private String commune=null;
        private String departement=null;
        private String codeInsee=null;
        
        
        public ReferentielCommune() {
        }

        /**
         * @param commune
         * @param departement
         */
        public ReferentielCommune(String commune, String code) {
                
                this.commune = commune;
                if(code.length() == 5) {
                        codeInsee = code;
                        departement = code.substring(0,2);
                } else {
                        departement = code;
                }
        }

        public String getCommune() {
                return commune;
        }


        public String getDepartement() {
                return departement;
        }

        public String getCodeInsee() {
                return codeInsee;
        }

}