ss: Replace AttributeNotFoundException with IOOBE for quark parameters
[deliverable/tracecompass.git] / tmf / org.eclipse.tracecompass.tmf.analysis.xml.ui / src / org / eclipse / tracecompass / internal / tmf / analysis / xml / ui / views / timegraph / XmlTimeGraphView.java
index 106e85e0f1b8425fbfca2374316e06261e9cd5e0..aa9f8fe7da0e604855866f7d131415bd564f0ea2 100644 (file)
@@ -336,43 +336,40 @@ public class XmlTimeGraphView extends AbstractTimeGraphView {
         int i = 0;
         List<Integer> quarks = Collections.singletonList(baseQuark);
 
-        try {
-            while (i < paths.length) {
-                List<Integer> subQuarks = new LinkedList<>();
-                /* Replace * by .* to have a regex string */
-                String name = paths[i].replaceAll("\\*", ".*"); //$NON-NLS-1$ //$NON-NLS-2$
-                for (int relativeQuark : quarks) {
-                    for (int quark : ss.getSubAttributes(relativeQuark, false, name)) {
-                        subQuarks.add(quark);
-                    }
+        while (i < paths.length) {
+            List<Integer> subQuarks = new LinkedList<>();
+            /* Replace * by .* to have a regex string */
+            String name = paths[i].replaceAll("\\*", ".*"); //$NON-NLS-1$ //$NON-NLS-2$
+            for (int relativeQuark : quarks) {
+                for (int quark : ss.getSubAttributes(relativeQuark, false, name)) {
+                    subQuarks.add(quark);
                 }
-                quarks = subQuarks;
-                i++;
             }
+            quarks = subQuarks;
+            i++;
+        }
 
-            /* Process each quark */
-            XmlEntry currentEntry = parentEntry;
-            Element displayElement = null;
-            Map<String, XmlEntry> entryMap = new HashMap<>();
-            if (!displayElements.isEmpty()) {
-                displayElement = displayElements.get(0);
-            }
-            for (int quark : quarks) {
-                currentEntry = parentEntry;
-                /* Process the current entry, if specified */
-                if (displayElement != null) {
-                    currentEntry = processEntry(entryElement, displayElement, parentEntry, quark, ss);
-                    entryMap.put(currentEntry.getId(), currentEntry);
-                }
-                /* Process the children entry of this entry */
-                for (Element subEntryEl : entryElements) {
-                    buildEntry(subEntryEl, currentEntry, quark);
-                }
+        /* Process each quark */
+        XmlEntry currentEntry = parentEntry;
+        Element displayElement = null;
+        Map<String, XmlEntry> entryMap = new HashMap<>();
+        if (!displayElements.isEmpty()) {
+            displayElement = displayElements.get(0);
+        }
+        for (int quark : quarks) {
+            currentEntry = parentEntry;
+            /* Process the current entry, if specified */
+            if (displayElement != null) {
+                currentEntry = processEntry(entryElement, displayElement, parentEntry, quark, ss);
+                entryMap.put(currentEntry.getId(), currentEntry);
             }
-            if (!entryMap.isEmpty()) {
-                buildTree(entryMap, parentEntry);
+            /* Process the children entry of this entry */
+            for (Element subEntryEl : entryElements) {
+                buildEntry(subEntryEl, currentEntry, quark);
             }
-        } catch (AttributeNotFoundException e) {
+        }
+        if (!entryMap.isEmpty()) {
+            buildTree(entryMap, parentEntry);
         }
     }
 
@@ -417,7 +414,7 @@ public class XmlTimeGraphView extends AbstractTimeGraphView {
             }
             entryEnd = oneInterval.getEndTime();
 
-        } catch (AttributeNotFoundException | StateSystemDisposedException e) {
+        } catch (StateSystemDisposedException e) {
         }
 
         return new XmlEntry(quark, displayQuark, parentEntry.getTrace(), ss.getAttributeName(quark),
This page took 0.037984 seconds and 5 git commands to generate.