r421 - in tags/4.4.5: resultinfos simulators
Author: echatellier Date: 2020-10-26 11:46:23 +0100 (Mon, 26 Oct 2020) New Revision: 421 Url: http://forge.codelutin.com/projects/isis-fish-data/repository/revisions/421 Log: Ajout des resultats : nombre d'oeufs pondus et recrutement par zone Added: tags/4.4.5/resultinfos/MatrixNumberOfEggsLaid.java tags/4.4.5/resultinfos/MatrixRecruitmentPerZone.java Modified: tags/4.4.5/simulators/DefaultSimulator.java Copied: tags/4.4.5/resultinfos/MatrixNumberOfEggsLaid.java (from rev 416, trunk/resultinfos/MatrixLbar.java) =================================================================== --- tags/4.4.5/resultinfos/MatrixNumberOfEggsLaid.java (rev 0) +++ tags/4.4.5/resultinfos/MatrixNumberOfEggsLaid.java 2020-10-26 10:46:23 UTC (rev 421) @@ -0,0 +1,39 @@ +/* + * #%L + * IsisFish data + * %% + * Copyright (C) 2020 Ifremer, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ +package resultinfos; + +import fr.ifremer.isisfish.result.AbstractResultInfo; + +/** + * Matrix with two dimensions + * Dimension 1 : TimeStep + * Dimension 2 : Zone (semantics : Dimension 1) + */ +public class MatrixNumberOfEggsLaid extends AbstractResultInfo { + + public static final String NAME = "MatrixNumberOfEggsLaid"; + + @Override + public String getDescription() { + return "do the doc of Result MatrixNumberOfEggsLaid"; + } +} Added: tags/4.4.5/resultinfos/MatrixRecruitmentPerZone.java =================================================================== --- tags/4.4.5/resultinfos/MatrixRecruitmentPerZone.java (rev 0) +++ tags/4.4.5/resultinfos/MatrixRecruitmentPerZone.java 2020-10-26 10:46:23 UTC (rev 421) @@ -0,0 +1,40 @@ +/* + * #%L + * IsisFish data + * %% + * Copyright (C) 2020 Ifremer, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ +package resultinfos; + +import fr.ifremer.isisfish.result.AbstractResultInfo; + +/** + * Matrix with two dimensions + * Dimension 1 : TimeStep + * Dimension 2 : Group (semantics : Dimension 1) + * Dimension 3 : Zone (semantics : Dimension 2) + */ +public class MatrixRecruitmentPerZone extends AbstractResultInfo { + + public static final String NAME = "MatrixRecruitmentPerZone"; + + @Override + public String getDescription() { + return "do the doc of Result MatrixRecruitmentPerZone"; + } +} Modified: tags/4.4.5/simulators/DefaultSimulator.java =================================================================== --- tags/4.4.5/simulators/DefaultSimulator.java 2020-09-08 12:57:02 UTC (rev 420) +++ tags/4.4.5/simulators/DefaultSimulator.java 2020-10-26 10:46:23 UTC (rev 421) @@ -456,15 +456,23 @@ // reproduction MatrixND R = info.getReproductionMatrix(month, N); + R.setName(MatrixNumberOfEggsLaid.NAME); log.debug("R: " + R); // ajout de la matrice R dans le suivi de la pop comme etant // la reproduction pour le mois courant. popMon.setReproduction(step, pop, N, biomass, R); + if (resManager.isEnabled(MatrixNumberOfEggsLaid.NAME)) { + resManager.addResult(step, pop, R); + } // recrutement MatrixND recruitment = popMon.getRecruitment(step, pop); + recruitment.setName(MatrixRecruitmentPerZone.NAME); log.debug("recruitment: " + recruitment); + if (resManager.isEnabled(MatrixRecruitmentPerZone.NAME)) { + resManager.addResult(step, pop, recruitment); + } // mortalite de la reproduction popMon.applyReproductionMortality(pop);
participants (1)
-
echatellier@users.forge.codelutin.com