Subversion Repositories eFlore/Applications.del

Rev

Rev 147 | Blame | Last modification | View Log | RSS feed

package org.tela_botanica.del.client.modeles;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

public class Observation implements Serializable {

        private static final long serialVersionUID = 840032625524143547L;

        private String auteur;

        private String species;

        private String nomRetenu;

        private String famille;

        private String localite;

        private String date;

        private String numNomenclatural;

        private List<String> motsClefs = new ArrayList<String>();

        private List<PropositionDetermination> imageCelValidationDatas = new ArrayList<PropositionDetermination>();

        private List<Image> images = new ArrayList<Image>();

        public String getAuteur() {
                return auteur;
        }

        public void setAuteur(String auteur) {
                this.auteur = auteur;
        }

        public String getSpecies() {
                return species;
        }

        public void setSpecies(String species) {
                this.species = species;
        }

        public String getNomRetenu() {
                return nomRetenu;
        }

        public void setNomRetenu(String commonName) {
                this.nomRetenu = commonName;
        }

        public String getFamille() {
                return famille;
        }

        public void setFamille(String famille) {
                this.famille = famille;
        }

        public String getLocalite() {
                return localite;
        }

        public void setLocalite(String localite) {
                this.localite = localite;
        }

        public String getDate() {
                return date;
        }

        public void setDate(String date) {
                this.date = date;
        }

        public String getNumNomenclatural() {
                return numNomenclatural;
        }

        public void setNumNomenclatural(String numNomenclatural) {
                this.numNomenclatural = numNomenclatural;
        }

        public List<PropositionDetermination> getImageCelValidationDatas() {
                return imageCelValidationDatas;
        }

        public void setImageCelValidationDatas(List<PropositionDetermination> imageCelValidationDatas) {
                this.imageCelValidationDatas = imageCelValidationDatas;
        }

        public List<String> getMotsClefs() {
                return motsClefs;
        }

        public void setMotsClefs(List<String> motsClefs) {
                this.motsClefs = motsClefs;
        }

        public void addImageCelValidationData(PropositionDetermination observationValidation) {
                imageCelValidationDatas.add(observationValidation);
        }

        public ArrayList<String> getPropositionsTaxonsData() {

                ArrayList<String> propositionsTaxonDatas = new ArrayList<String>();
                for (PropositionDetermination observationValidation : imageCelValidationDatas) {
                        String espece = observationValidation.getEspece();
                        if (espece != "" && !propositionsTaxonDatas.contains(espece)) {
                                propositionsTaxonDatas.add(observationValidation.getEspece());
                        }
                }

                return propositionsTaxonDatas;
        }

        public List<Image> getImages() {
                return images;
        }

        public void setImages(List<Image> images) {
                this.images = images;
        }

}