tmf.xml: replace exception with log error message in TmfXmlStateValue
authorJean-Christian Kouame <jean-christian.kouame@ericsson.com>
Mon, 22 Aug 2016 16:03:28 +0000 (12:03 -0400)
committerJean-Christian Kouame <jean-christian.kouame@ericsson.com>
Wed, 24 Aug 2016 02:57:35 +0000 (22:57 -0400)
This patch removes an exception that blocks the execution of Trace
Compass when hit. The exception is replaced by a log error message.

Change-Id: I684cbac6038665329a61d16720ec689961209f34
Signed-off-by: Jean-Christian Kouame <jean-christian.kouame@ericsson.com>
Reviewed-on: https://git.eclipse.org/r/79442
Reviewed-by: Hudson CI
Reviewed-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
Tested-by: Bernd Hufmann <bernd.hufmann@ericsson.com>
tmf/org.eclipse.tracecompass.tmf.analysis.xml.core/src/org/eclipse/tracecompass/internal/tmf/analysis/xml/core/model/TmfXmlStateValue.java

index 827dc77d6ef22d09c4a6abcfbc9c331c0890604e..cd74f86d4b3a2db81b3ed7a6dfd78ccc4a4ad2eb 100644 (file)
@@ -16,6 +16,7 @@ import java.util.List;
 
 import org.eclipse.jdt.annotation.NonNull;
 import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.internal.tmf.analysis.xml.core.Activator;
 import org.eclipse.tracecompass.internal.tmf.analysis.xml.core.module.IXmlStateSystemContainer;
 import org.eclipse.tracecompass.internal.tmf.analysis.xml.core.stateprovider.TmfXmlStrings;
 import org.eclipse.tracecompass.statesystem.core.ITmfStateSystem;
@@ -397,7 +398,8 @@ public abstract class TmfXmlStateValue implements ITmfXmlStateValue {
             quark = attribute.getAttributeQuark(event, quark, scenarioInfo);
             /* the query is not valid, we stop the state change */
             if (quark == IXmlStateSystemContainer.ERROR_QUARK) {
-                throw new AttributeNotFoundException("Not found XML attribute " + attribute); //$NON-NLS-1$
+                Activator.logError("Not found XML attribute " + attribute); //$NON-NLS-1$
+                return;
             }
         }
 
This page took 0.026126 seconds and 5 git commands to generate.