This is an automated email from the git hooks/post-receive script. New commit to branch develop in repository tutti. See http://git.codelutin.com/tutti.git commit fcf6589e9f43c09b38bfd56a1b8de39dfa248478 Author: Tony CHEMIT <chemit@codelutin.com> Date: Fri Aug 29 16:04:32 2014 +0200 clean code --- .../tutti/service/catches/WeightComputingService.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tutti-service/src/main/java/fr/ifremer/tutti/service/catches/WeightComputingService.java b/tutti-service/src/main/java/fr/ifremer/tutti/service/catches/WeightComputingService.java index 09ad3c7..8ff4542 100644 --- a/tutti-service/src/main/java/fr/ifremer/tutti/service/catches/WeightComputingService.java +++ b/tutti-service/src/main/java/fr/ifremer/tutti/service/catches/WeightComputingService.java @@ -185,8 +185,8 @@ public class WeightComputingService extends AbstractTuttiService { Float speciesTotalComputedUnsortedWeight = 0f; if (rootSpeciesBatch != null) { - for (int i = 0; i < rootSpeciesBatch.getChildren().size(); i++) { - SpeciesBatch row = rootSpeciesBatch.getChildren().get(i); + List<SpeciesBatch> speciesBatches = rootSpeciesBatch.getChildren(); + for (SpeciesBatch row : speciesBatches) { Float weight = Numbers.getValueOrComputedValue( row.getSampleCategoryWeight(), row.getSampleCategoryComputedWeight()); @@ -242,8 +242,8 @@ public class WeightComputingService extends AbstractTuttiService { Float benthosTotalComputedUnsortedWeight = 0f; if (rootBenthosBatch != null) { - for (int i = 0; i < rootBenthosBatch.getChildren().size(); i++) { - BenthosBatch row = rootBenthosBatch.getChildren().get(i); + List<BenthosBatch> benthosBatches = rootBenthosBatch.getChildren(); + for (BenthosBatch row : benthosBatches) { Float weight = Numbers.getValueOrComputedValue( row.getSampleCategoryWeight(), row.getSampleCategoryComputedWeight()); @@ -299,8 +299,8 @@ public class WeightComputingService extends AbstractTuttiService { Float marineLitterTotalComputedWeight = 0f; if (rootMarineLitterBatch != null) { - for (int i = 0; i < rootMarineLitterBatch.getChildren().size(); i++) { - MarineLitterBatch row = rootMarineLitterBatch.getChildren().get(i); + List<MarineLitterBatch> marineLitterBatches = rootMarineLitterBatch.getChildren(); + for (MarineLitterBatch row : marineLitterBatches) { Float rowWeight = row.getWeight(); if (rowWeight == null) { marineLitterTotalComputedWeight = null; -- To stop receiving notification emails like this one, please contact codelutin.com SCM administrator <admin+scm@codelutin.com>.