lami: possible ressource leak on IntStream
[deliverable/tracecompass.git] / analysis / org.eclipse.tracecompass.analysis.lami.ui / src / org / eclipse / tracecompass / internal / provisional / analysis / lami / ui / views / LamiSeriesDialog.java
index 8aebff80c4bdd85ad0766907a99217bef3f665ad..ddb36a022ddbabe2442ae9ed641a67dd71e2add6 100644 (file)
@@ -16,7 +16,6 @@ import java.util.Arrays;
 import java.util.List;
 import java.util.function.Function;
 import java.util.function.Predicate;
-import java.util.stream.IntStream;
 
 import org.eclipse.jdt.annotation.Nullable;
 import org.eclipse.jface.dialogs.Dialog;
@@ -457,8 +456,8 @@ public class LamiSeriesDialog extends SelectionDialog {
      */
     public boolean[] getXCheckBoxOptionValues() {
         boolean[] selections = new boolean[fXCheckBoxOptions.size()];
-        if (selections.length != 0) {
-            IntStream.range(0, selections.length).forEach(i -> selections[i] = fXCheckBoxOptions.get(i).getValue());
+        for (int i = 0; i < selections.length; i++) {
+            selections[i] = fXCheckBoxOptions.get(i).getValue();
         }
         return selections;
     }
@@ -468,8 +467,8 @@ public class LamiSeriesDialog extends SelectionDialog {
      */
     public boolean[] getYCheckBoxOptionValues() {
         boolean[] selections = new boolean[fYCheckBoxOptions.size()];
-        if (selections.length != 0) {
-            IntStream.range(0, selections.length).forEach(i -> selections[i] = fYCheckBoxOptions.get(i).getValue());
+        for (int i = 0; i < selections.length; i++) {
+            selections[i] = fYCheckBoxOptions.get(i).getValue();
         }
         return selections;
     }
This page took 0.025234 seconds and 5 git commands to generate.