From echatellier@users.forge.codelutin.com Wed Nov 23 22:15:54 2016
From: echatellier@users.forge.codelutin.com
To: isis-fish-data-commits@list.isis-fish.org
Subject: [Isis-fish-data-commits] r392 - trunk/exports
Date: Wed, 23 Nov 2016 22:15:53 +0100
Message-ID: <20161123211553.C5FE45DE6AD@goh.codelutin.com>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="===============1900069633240905399=="

--===============1900069633240905399==
Content-Type: text/plain; charset="utf-8"
Content-Transfer-Encoding: quoted-printable

Author: echatellier
Date: 2016-11-23 22:15:37 +0100 (Wed, 23 Nov 2016)
New Revision: 392

Url: http://forge.codelutin.com/projects/isis-fish-data/repository/revisions/=
392

Log:
Correction de l'export de rejet

Modified:
   trunk/exports/RejetsPoids.java

Modified: trunk/exports/RejetsPoids.java
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
--- trunk/exports/RejetsPoids.java	2016-08-01 09:11:26 UTC (rev 391)
+++ trunk/exports/RejetsPoids.java	2016-11-23 21:15:37 UTC (rev 392)
@@ -108,16 +108,18 @@
         for (Population pop : simulation.getParameter().getPopulations()) {
             MatrixND mat =3D simulation.getResultStorage().getMatrix(step, p=
op, MatrixDiscardsWeightPerStrMetPerZonePop.NAME);
             mat =3D mat.sumOverDim(0); //sum on strategy
-            for (MatrixIterator i =3D mat.iterator(); i.hasNext();) {
-                i.next();
-                Object[] sems =3D i.getSemanticsCoordinates();
-                Metier metier =3D (Metier) sems[1];
-                PopulationGroup group =3D (PopulationGroup) sems[2];
-                Zone zone =3D (Zone) sems[3];
-
-                double val =3D i.getValue();
-                out.write(step.getStep() + ";" + pop.getName() + ";" + metie=
r.getName() + ";"
-                        + group.getId() + ";" + zone.getName() + ";" + val +=
 "\n");
+            if (mat !=3D null) {
+                for (MatrixIterator i =3D mat.iterator(); i.hasNext();) {
+                    i.next();
+                    Object[] sems =3D i.getSemanticsCoordinates();
+                    Metier metier =3D (Metier) sems[1];
+                    PopulationGroup group =3D (PopulationGroup) sems[2];
+                    Zone zone =3D (Zone) sems[3];
+   =20
+                    double val =3D i.getValue();
+                    out.write(step.getStep() + ";" + pop.getName() + ";" + m=
etier.getName() + ";"
+                            + group.getId() + ";" + zone.getName() + ";" + v=
al + "\n");
+                }
             }
         }
     }


--===============1900069633240905399==--


