tmf : Make waitForInitialization() return a boolean
[deliverable/tracecompass.git] / tmf / org.eclipse.tracecompass.tmf.analysis.xml.ui / src / org / eclipse / tracecompass / tmf / analysis / xml / ui / views / timegraph / XmlTimeGraphView.java
index 1027ee4d6f341dd601c6630feaedec24d30c18df..c6f46ae00d82514e84442eb31e5a0fadf4ab148f 100644 (file)
@@ -51,7 +51,6 @@ import org.eclipse.tracecompass.tmf.analysis.xml.core.module.XmlUtils;
 import org.eclipse.tracecompass.tmf.analysis.xml.core.stateprovider.TmfXmlStrings;
 import org.eclipse.tracecompass.tmf.analysis.xml.ui.views.timegraph.XmlEntry.EntryDisplayType;
 import org.eclipse.tracecompass.tmf.core.statesystem.ITmfAnalysisModuleWithStateSystems;
-import org.eclipse.tracecompass.tmf.core.statesystem.TmfStateSystemAnalysisModule;
 import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
 import org.eclipse.tracecompass.tmf.core.trace.TmfTraceManager;
 import org.eclipse.tracecompass.tmf.core.trace.TmfTraceUtils;
@@ -254,7 +253,7 @@ public class XmlTimeGraphView extends AbstractTimeGraphView {
             return;
         }
 
-        Set<ITmfAnalysisModuleWithStateSystems> stateSystemModules = new HashSet<>();
+        Set<@NonNull ITmfAnalysisModuleWithStateSystems> stateSystemModules = new HashSet<>();
         if (analysisIds.isEmpty()) {
             /*
              * No analysis specified, take all state system analysis modules
@@ -275,8 +274,8 @@ public class XmlTimeGraphView extends AbstractTimeGraphView {
             if (!status.isOK()) {
                 return;
             }
-            if (module instanceof TmfStateSystemAnalysisModule) {
-                ((TmfStateSystemAnalysisModule) module).waitForInitialization();
+            if (!module.waitForInitialization()) {
+                return;
             }
             for (ITmfStateSystem ssq : module.getStateSystems()) {
                 ssq.waitUntilBuilt();
This page took 0.02564 seconds and 5 git commands to generate.