Internalize some classes and fix a pile of warnings
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.ui / src / org / eclipse / linuxtools / internal / tmf / ui / parsers / custom / CustomXmlTrace.java
index 7bbe5bb4177c132413c4c3e994eace272cb7fc5f..4c0c0d8c827f540bec06c977998fd4d657a07526 100644 (file)
@@ -24,7 +24,7 @@ import javax.xml.parsers.ParserConfigurationException;
 \r
 import org.eclipse.core.resources.IProject;\r
 import org.eclipse.core.resources.IResource;\r
-import org.eclipse.linuxtools.internal.tmf.ui.TmfUiPlugin;\r
+import org.eclipse.linuxtools.internal.tmf.ui.Activator;\r
 import org.eclipse.linuxtools.internal.tmf.ui.parsers.custom.CustomXmlTraceDefinition.InputAttribute;\r
 import org.eclipse.linuxtools.internal.tmf.ui.parsers.custom.CustomXmlTraceDefinition.InputElement;\r
 import org.eclipse.linuxtools.tmf.core.event.TmfTimestamp;\r
@@ -98,10 +98,10 @@ public class CustomXmlTrace extends TmfTrace<CustomXmlEvent> implements ITmfEven
             }\r
             return context;\r
         } catch (final FileNotFoundException e) {\r
-            TmfUiPlugin.getDefault().logError("Error seeking event. File not found: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error seeking event. File not found: " + getPath(), e); //$NON-NLS-1$\r
             return context;\r
         } catch (final IOException e) {\r
-            TmfUiPlugin.getDefault().logError("Error seeking event. File: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error seeking event. File: " + getPath(), e); //$NON-NLS-1$\r
             return context;\r
         }\r
 \r
@@ -125,10 +125,10 @@ public class CustomXmlTrace extends TmfTrace<CustomXmlEvent> implements ITmfEven
             context.setRank(ITmfContext.UNKNOWN_RANK);\r
             return context;\r
         } catch (final FileNotFoundException e) {\r
-            TmfUiPlugin.getDefault().logError("Error seeking event. File not found: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error seeking event. File not found: " + getPath(), e); //$NON-NLS-1$\r
             return new CustomXmlTraceContext(NULL_LOCATION, ITmfContext.UNKNOWN_RANK);\r
         } catch (final IOException e) {\r
-            TmfUiPlugin.getDefault().logError("Error seeking event. File: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error seeking event. File: " + getPath(), e); //$NON-NLS-1$\r
             return new CustomXmlTraceContext(NULL_LOCATION, ITmfContext.UNKNOWN_RANK);\r
         } finally {\r
             if (raFile != null) {\r
@@ -149,9 +149,9 @@ public class CustomXmlTrace extends TmfTrace<CustomXmlEvent> implements ITmfEven
                 return (double) ((Long) location.getLocation()) / raFile.length();\r
             }\r
         } catch (final FileNotFoundException e) {\r
-            TmfUiPlugin.getDefault().logError("Error getting location ration. File not found: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error getting location ration. File not found: " + getPath(), e); //$NON-NLS-1$\r
         } catch (final IOException e) {\r
-            TmfUiPlugin.getDefault().logError("Error getting location ration. File: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error getting location ration. File: " + getPath(), e); //$NON-NLS-1$\r
         } finally {\r
             if (raFile != null) {\r
                 try {\r
@@ -216,7 +216,7 @@ public class CustomXmlTrace extends TmfTrace<CustomXmlEvent> implements ITmfEven
                     rawPos = context.raFile.getFilePointer();\r
                 }\r
             } catch (final IOException e) {\r
-                TmfUiPlugin.getDefault().logError("Error pasing event. File: " + getPath(), e); //$NON-NLS-1$\r
+                Activator.getDefault().logError("Error pasing event. File: " + getPath(), e); //$NON-NLS-1$\r
                 \r
             }\r
             context.setLocation(NULL_LOCATION);\r
@@ -254,11 +254,11 @@ public class CustomXmlTrace extends TmfTrace<CustomXmlEvent> implements ITmfEven
             final Document doc = db.parse(new ByteArrayInputStream(elementBuffer.toString().getBytes()));\r
             return doc.getDocumentElement();\r
         } catch (final ParserConfigurationException e) {\r
-            TmfUiPlugin.getDefault().logError("Error parsing element buffer. File:" + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error parsing element buffer. File:" + getPath(), e); //$NON-NLS-1$\r
         } catch (final SAXException e) {\r
-            TmfUiPlugin.getDefault().logError("Error parsing element buffer. File:" + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error parsing element buffer. File:" + getPath(), e); //$NON-NLS-1$\r
         } catch (final IOException e) {\r
-            TmfUiPlugin.getDefault().logError("Error parsing element buffer. File: " + getPath(), e); //$NON-NLS-1$\r
+            Activator.getDefault().logError("Error parsing element buffer. File: " + getPath(), e); //$NON-NLS-1$\r
         }\r
         return null;\r
     }\r
This page took 0.025354 seconds and 5 git commands to generate.