From: Loïc Prieur-Drevon Date: Wed, 26 Apr 2017 20:24:28 +0000 (-0400) Subject: tmf: remove deprecated methods from tmf X-Git-Url: https://git.efficios.com/?a=commitdiff_plain;h=4b40a764980500b35c92f5a5da561905bbfcfcce;p=deliverable%2Ftracecompass.git tmf: remove deprecated methods from tmf Change-Id: Ie45fc1ab795e8226a09486ef1f6e95b2642a92e2 Signed-off-by: Loïc Prieur-Drevon Reviewed-on: https://git.eclipse.org/r/95843 Reviewed-by: Hudson CI Reviewed-by: Bernd Hufmann Tested-by: Bernd Hufmann Reviewed-by: Matthew Khouzam --- diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/debuginfo/SourceCallsite.java b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/debuginfo/SourceCallsite.java index 76446ac4cf..12ddbb5f59 100644 --- a/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/debuginfo/SourceCallsite.java +++ b/lttng/org.eclipse.tracecompass.lttng2.ust.core/src/org/eclipse/tracecompass/lttng2/ust/core/analysis/debuginfo/SourceCallsite.java @@ -42,7 +42,7 @@ public class SourceCallsite extends TmfCallsite { public String toString() { StringBuilder builder = new StringBuilder(); builder.append(getFileName()).append(':'); - builder.append(Long.toString(getLineNumber())); + builder.append(getLineNo()); return builder.toString(); } diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF index fce0690148..f641054f90 100644 --- a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF +++ b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Bundle-Vendor: %Bundle-Vendor -Bundle-Version: 2.1.0.qualifier +Bundle-Version: 3.0.0.qualifier Bundle-Localization: plugin Bundle-SymbolicName: org.eclipse.tracecompass.lttng2.ust.ui;singleton:=true Bundle-Activator: org.eclipse.tracecompass.internal.lttng2.ust.ui.Activator @@ -18,8 +18,7 @@ Require-Bundle: org.eclipse.core.resources, org.eclipse.tracecompass.tmf.ctf.core Export-Package: org.eclipse.tracecompass.internal.lttng2.ust.ui;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests", org.eclipse.tracecompass.internal.lttng2.ust.ui.analysis.debuginfo;x-internal:=true, - org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests,org.eclipse.tracecompass.lttng2.ust.ui.swtbot.tests", - org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack + org.eclipse.tracecompass.internal.lttng2.ust.ui.views.memusage;x-friends:="org.eclipse.tracecompass.lttng2.ust.ui.tests,org.eclipse.tracecompass.lttng2.ust.ui.swtbot.tests" Import-Package: com.google.common.base, com.google.common.collect, org.swtchart diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/analysis/debuginfo/UstDebugInfoSymbolProvider.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/analysis/debuginfo/UstDebugInfoSymbolProvider.java index f98af9572c..f3416028d3 100644 --- a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/analysis/debuginfo/UstDebugInfoSymbolProvider.java +++ b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/internal/lttng2/ust/ui/analysis/debuginfo/UstDebugInfoSymbolProvider.java @@ -16,10 +16,7 @@ import org.eclipse.tracecompass.lttng2.ust.core.analysis.debuginfo.FunctionLocat import org.eclipse.tracecompass.lttng2.ust.core.analysis.debuginfo.UstDebugInfoAnalysisModule; import org.eclipse.tracecompass.lttng2.ust.core.analysis.debuginfo.UstDebugInfoBinaryAspect; import org.eclipse.tracecompass.lttng2.ust.core.analysis.debuginfo.UstDebugInfoFunctionAspect; -import org.eclipse.tracecompass.lttng2.ust.core.analysis.debuginfo.UstDebugInfoSourceAspect; import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace; -import org.eclipse.tracecompass.tmf.core.event.lookup.ITmfCallsite; -import org.eclipse.tracecompass.tmf.core.event.lookup.TmfCallsite; import org.eclipse.tracecompass.tmf.core.symbols.DefaultSymbolProvider; import org.eclipse.tracecompass.tmf.ui.symbols.ISymbolProvider; import org.eclipse.tracecompass.tmf.ui.symbols.ISymbolProviderPreferencePage; @@ -70,26 +67,9 @@ public class UstDebugInfoSymbolProvider extends DefaultSymbolProvider implements return (loc == null ? null : loc.getFunctionName()); } - @Deprecated - @Override - public @Nullable TmfCallsite getSymbolInfo(int pid, long timestamp, long address) { - BinaryCallsite bc = UstDebugInfoBinaryAspect.getBinaryCallsite(getTrace(), pid, timestamp, address); - if (bc == null) { - return null; - } - - return UstDebugInfoSourceAspect.getSourceCallsite(getTrace(), bc); - } - @Override public @NonNull ISymbolProviderPreferencePage createPreferencePage() { return new UstDebugInfoSymbolProviderPreferencePage(this); } - @Deprecated - @Override - public @Nullable ITmfCallsite getSymbolInfo(long address) { - return null; - } - } diff --git a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java b/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java deleted file mode 100644 index f1241e54aa..0000000000 --- a/lttng/org.eclipse.tracecompass.lttng2.ust.ui/src/org/eclipse/tracecompass/lttng2/ust/ui/analysis/callstack/LttngUstCallStackAnalysis.java +++ /dev/null @@ -1,95 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2014, 2016 Ericsson - * - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Alexandre Montplaisir - Initial API and implementation - * Bernd Hufmann - Added analysis requirements - *******************************************************************************/ - -package org.eclipse.tracecompass.lttng2.ust.ui.analysis.callstack; - -import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull; - -import java.util.Set; - -import org.eclipse.jdt.annotation.NonNull; -import org.eclipse.jdt.annotation.Nullable; -import org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackAnalysisRequirement; -import org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackProvider; -import org.eclipse.tracecompass.lttng2.ust.core.trace.LttngUstTrace; -import org.eclipse.tracecompass.lttng2.ust.core.trace.layout.ILttngUstEventLayout; -import org.eclipse.tracecompass.tmf.core.analysis.requirements.TmfAbstractAnalysisRequirement; -import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException; -import org.eclipse.tracecompass.tmf.core.statesystem.ITmfStateProvider; -import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; -import org.eclipse.tracecompass.tmf.ui.views.callstack.AbstractCallStackAnalysis; - -import com.google.common.collect.ImmutableSet; - -/** - * Call-stack analysis to populate the TMF CallStack View from UST cyg-profile - * events. - * - * @author Alexandre Montplaisir - * @deprecated This analysis was moved to core as - * {@link org.eclipse.tracecompass.internal.lttng2.ust.core.callstack.LttngUstCallStackAnalysis} - * and is now internal - */ -@Deprecated -public class LttngUstCallStackAnalysis extends AbstractCallStackAnalysis { - - /** - * ID - * - * @since 2.0 - */ - public static final String ID = "org.eclipse.linuxtools.lttng2.ust.analysis.callstack"; //$NON-NLS-1$ - - private @Nullable Set<@NonNull TmfAbstractAnalysisRequirement> fAnalysisRequirements = null; - - /** - * @since 1.0 - */ - @Override - public boolean setTrace(ITmfTrace trace) throws TmfAnalysisException { - if (!(trace instanceof LttngUstTrace)) { - return false; - } - return super.setTrace(trace); - } - - /** - * @since 2.1 - */ - @Override - public LttngUstTrace getTrace() { - return (LttngUstTrace) super.getTrace(); - } - - @Override - protected ITmfStateProvider createStateProvider() { - return new LttngUstCallStackProvider(checkNotNull(getTrace())); - } - - @Override - public @NonNull Iterable<@NonNull TmfAbstractAnalysisRequirement> getAnalysisRequirements() { - - Set<@NonNull TmfAbstractAnalysisRequirement> requirements = fAnalysisRequirements; - if (requirements == null) { - LttngUstTrace trace = getTrace(); - ILttngUstEventLayout layout = ILttngUstEventLayout.DEFAULT_LAYOUT; - if (trace != null) { - layout = trace.getEventLayout(); - } - requirements = ImmutableSet.of(new LttngUstCallStackAnalysisRequirement(layout)); - fAnalysisRequirements = requirements; - } - return requirements; - } - -} diff --git a/tmf/org.eclipse.tracecompass.tmf.core/META-INF/MANIFEST.MF b/tmf/org.eclipse.tracecompass.tmf.core/META-INF/MANIFEST.MF index 6f565394ca..ec16833f06 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/META-INF/MANIFEST.MF +++ b/tmf/org.eclipse.tracecompass.tmf.core/META-INF/MANIFEST.MF @@ -2,7 +2,7 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Bundle-Vendor: %Bundle-Vendor -Bundle-Version: 2.4.0.qualifier +Bundle-Version: 3.0.0.qualifier Bundle-Localization: plugin Bundle-SymbolicName: org.eclipse.tracecompass.tmf.core;singleton:=true Bundle-Activator: org.eclipse.tracecompass.internal.tmf.core.Activator diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAbstractAnalysisModule.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAbstractAnalysisModule.java index 28af69621d..4eebb2e75f 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAbstractAnalysisModule.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAbstractAnalysisModule.java @@ -158,7 +158,7 @@ public abstract class TmfAbstractAnalysisModule extends TmfComponent * Gets the trace * * @return The trace - * @since 2.4 + * @since 3.0 */ @Nullable public ITmfTrace getTrace() { return fTrace; @@ -303,7 +303,7 @@ public abstract class TmfAbstractAnalysisModule extends TmfComponent * initialized when the exception occurred, this method could mark the * initialization as failed. * - * @since 2.4 + * @since 3.0 */ protected void onFail() { // Do nothing by default diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAnalysisManager.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAnalysisManager.java index 207a3cc6a2..fdaabff1a7 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAnalysisManager.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/analysis/TmfAnalysisManager.java @@ -181,25 +181,6 @@ public class TmfAnalysisManager { } } - /** - * Get the parameter providers that apply to the requested trace - * - * @param module - * Analysis module - * @param trace - * The trace - * @return The set of parameter providers that apply to a trace for this module - * @deprecated Use the - * {@link #getParameterProvidersForModule(IAnalysisModule, ITmfTrace)} - * method that returns a set instead. - */ - @Deprecated - public static List getParameterProviders(IAnalysisModule module, ITmfTrace trace) { - /* Call the method that returns a set */ - Set providerList = getParameterProvidersForModule(module, trace); - return new ArrayList<>(providerList); - } - /** * Get the parameter providers that apply to the requested trace * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/ITmfCallsite.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/ITmfCallsite.java index 146b87772a..0571395ac2 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/ITmfCallsite.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/ITmfCallsite.java @@ -36,32 +36,11 @@ public interface ITmfCallsite { */ @NonNull String getFileName(); - /** - * Returns the function name of the call site. - * - * @return the function name or null - * @deprecated Should not be part of this interface anymore. - */ - @Deprecated - @Nullable String getFunctionName(); - - /** - * Returns the line number of the call site. - * - * @return the line number - * @deprecated Use {@link #getLineNo()} instead, which can return null. - */ - @Deprecated - long getLineNumber(); - /** * Returns the line number of the call site. * * @return The line number, or 'null' if unavailable * @since 2.1 */ - default @Nullable Long getLineNo() { - /* TODO Change to abstract method once getLineNumber() is removed */ - return getLineNumber(); - } + @Nullable Long getLineNo(); } diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/TmfCallsite.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/TmfCallsite.java index 818a581a74..7bad791463 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/TmfCallsite.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/lookup/TmfCallsite.java @@ -12,8 +12,6 @@ package org.eclipse.tracecompass.tmf.core.event.lookup; -import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull; - import java.util.Objects; import org.eclipse.jdt.annotation.NonNull; @@ -40,22 +38,6 @@ public class TmfCallsite implements ITmfCallsite { // Constructors // ------------------------------------------------------------------------ - /** - * Default constructor. - * - * @param fileName - * - a file name - * @param functionName - * - a function name - * @param lineNumber - * - a line number - * @deprecated Use {@link #TmfCallsite(String, Long)} instead. - */ - @Deprecated - public TmfCallsite(String fileName, String functionName, long lineNumber) { - this(checkNotNull(fileName), lineNumber); - } - /** * Constructor * @@ -90,20 +72,6 @@ public class TmfCallsite implements ITmfCallsite { return fFileName; } - @Deprecated - @Override - public String getFunctionName() { - return ""; //$NON-NLS-1$ - } - - @Deprecated - @Override - public long getLineNumber() { - Long lineNumber = fLineNumber; - return (lineNumber == null ? -1 : lineNumber.longValue()); - } - - /** * @since 2.1 */ diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/matching/TmfEventMatches.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/matching/TmfEventMatches.java index e42f69c372..8ad73ae5a4 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/matching/TmfEventMatches.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/event/matching/TmfEventMatches.java @@ -57,19 +57,6 @@ public class TmfEventMatches implements IMatchProcessingUnit { return fMatchCount; } - /** - * Returns the match at the specified index - * - * @param index - * The index of the match to get - * @return The match at index or null or not present - * @deprecated Matches are not kept anymore, they use up memory for no real reason - */ - @Deprecated - public TmfEventDependency getMatch(int index) { - return null; - } - @Override public String toString() { return getClass().getSimpleName() + " [ Number of matches found: " + fMatchCount + " ]"; //$NON-NLS-1$ //$NON-NLS-2$ diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/exceptions/TmfAnalysisException.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/exceptions/TmfAnalysisException.java index 3170db633f..adeb6f4d88 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/exceptions/TmfAnalysisException.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/exceptions/TmfAnalysisException.java @@ -48,7 +48,7 @@ public class TmfAnalysisException extends Exception { * * @param cause * The cause - * @since 2.4 + * @since 3.0 */ public TmfAnalysisException(Throwable cause) { super(cause); diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEvent.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEvent.java index 4eba7d848b..3d6f43a04a 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEvent.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEvent.java @@ -12,11 +12,9 @@ package org.eclipse.tracecompass.tmf.core.parsers.custom; -import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull; import static org.eclipse.tracecompass.common.core.NonNullUtils.nullToEmptyString; import java.text.ParseException; -import java.util.Collection; import java.util.LinkedHashMap; import java.util.Map; import java.util.Map.Entry; @@ -37,8 +35,6 @@ import org.eclipse.tracecompass.tmf.core.timestamp.TmfTimestampFormat; import org.eclipse.tracecompass.tmf.core.trace.ITmfContext; import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; -import com.google.common.collect.Iterables; - /** * Base event for custom text parsers. * @@ -53,11 +49,6 @@ public class CustomEvent extends TmfEvent { TIMESTAMP_INPUT_FORMAT } - /** Input format key - * @deprecated Use {@link Key#TIMESTAMP_INPUT_FORMAT} instead. */ - @Deprecated - protected static final String TIMESTAMP_INPUT_FORMAT_KEY = "CE_TS_I_F"; //$NON-NLS-1$ - /** Empty message */ protected static final String NO_MESSAGE = ""; //$NON-NLS-1$ @@ -224,25 +215,6 @@ public class CustomEvent extends TmfEvent { // Other operations // ------------------------------------------------------------------------ - /** - * Get the contents of an event table cell for this event's row. - * - * @param index - * The ID/index of the field to display. This corresponds to the - * index in the event content. - * @return The String to display in the cell - * @deprecated Use {@link ITmfEventField#getField(String...)} instead. - */ - @Deprecated - public String getEventString(int index) { - Collection fields = getContent().getFields(); - if (index < 0 || index >= fields.size()) { - return ""; //$NON-NLS-1$ - } - - return nullToEmptyString(checkNotNull(Iterables.get(fields, index)).getValue()); - } - private void processData() { // Remove the values as they are processed, so we can process the extra values at the end String timestampString = fData.remove(Tag.TIMESTAMP); diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEventType.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEventType.java index 49014c187c..eead837af0 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEventType.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomEventType.java @@ -12,8 +12,6 @@ package org.eclipse.tracecompass.tmf.core.parsers.custom; -import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull; - import org.eclipse.jdt.annotation.NonNull; import org.eclipse.tracecompass.tmf.core.event.ITmfEventField; import org.eclipse.tracecompass.tmf.core.event.TmfEventField; @@ -29,19 +27,6 @@ public abstract class CustomEventType extends TmfEventType { private static final @NonNull String EMPTY = ""; //$NON-NLS-1$ private @NonNull String fEventName; - /** - * Constructor - * - * @param definition - * Trace definition - * @deprecated Use {@link #CustomEventType(String, ITmfEventField)} instead. - */ - @Deprecated - public CustomEventType(CustomTraceDefinition definition) { - super(EMPTY, getRootField(definition)); - fEventName = checkNotNull(definition.definitionName); - } - /** * Constructor * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTraceDefinition.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTraceDefinition.java index 55efec0bad..4865674933 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTraceDefinition.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTraceDefinition.java @@ -139,21 +139,6 @@ public abstract class CustomTraceDefinition { */ public static final @NonNull String SEPARATOR = " | "; //$NON-NLS-1$ - /** Timestamp tag - * @deprecated Use {@link Tag#TIMESTAMP} instead. */ - @Deprecated - public static final String TAG_TIMESTAMP = Messages.CustomTraceDefinition_timestampTag; - - /** Message tag - * @deprecated Use {@link Tag#MESSAGE} instead. */ - @Deprecated - public static final String TAG_MESSAGE = Messages.CustomTraceDefinition_messageTag; - - /** "Other" tag - * @deprecated Use {@link Tag#OTHER} instead. */ - @Deprecated - public static final String TAG_OTHER = Messages.CustomTraceDefinition_otherTag; - private static final String TMF_CUSTOM_TRACE_BUILTIN_EXTENSION_ID = "org.eclipse.tracecompass.tmf.core.custom.trace"; //$NON-NLS-1$ private static final String ATTRIBUTE_NAME_FILE = "file"; //$NON-NLS-1$ private static final String ATTRIBUTE_NAME_TRACE_CONTENT_TYPE = "traceContentType"; //$NON-NLS-1$ @@ -183,30 +168,6 @@ public abstract class CustomTraceDefinition { /** Name of this column */ public @NonNull String name; - /** - * Default constructor (empty) - * @deprecated Use {@link OutputColumn#OutputColumn(Tag, String)} - * instead. - */ - @Deprecated - public OutputColumn() { - this(Tag.IGNORE, ""); //$NON-NLS-1$ - } - - /** - * Constructor - * - * @param name - * Name of this output column - * @deprecated Use {@link OutputColumn#OutputColumn(Tag, String)} - * instead. - */ - @Deprecated - public OutputColumn(@NonNull String name) { - this.tag = Tag.OTHER; - this.name = name; - } - /** * Constructor * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtEventType.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtEventType.java index 613373f9d7..58a36ba7c2 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtEventType.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtEventType.java @@ -22,19 +22,6 @@ import org.eclipse.tracecompass.tmf.core.event.ITmfEventField; */ public class CustomTxtEventType extends CustomEventType { - /** - * Constructor - * - * @param definition - * Custom text trace definition - * @deprecated Use {@link #CustomTxtEventType(String, ITmfEventField)} - * instead. - */ - @Deprecated - public CustomTxtEventType(CustomTxtTraceDefinition definition) { - super(definition); - } - /** * Constructor * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtTrace.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtTrace.java index 3e5629efe7..765c70766e 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtTrace.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomTxtTrace.java @@ -586,7 +586,7 @@ public class CustomTxtTrace extends TmfTrace implements ITmfPersistentlyIndexabl } /** - * @since 2.4 + * @since 3.0 */ @Override public synchronized ITmfTimestamp readEnd() { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEvent.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEvent.java index c35e1b4e80..7ab3af2017 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEvent.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEvent.java @@ -73,19 +73,6 @@ public class CustomXmlEvent extends CustomEvent { super.setContent(content); } - /** - * Parse an entry. - * - * @param value Value - * @param name Name - * @param inputAction Input action - * @param inputFormat Input format - * @deprecated Use {@link #parseInput(String, Tag, String, int, String)} instead. - */ - @Deprecated - public void parseInput(String value, String name, int inputAction, String inputFormat) { - } - /** * Parse an entry. * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEventType.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEventType.java index 90156b9fc2..2dbaf28ae9 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEventType.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlEventType.java @@ -22,19 +22,6 @@ import org.eclipse.tracecompass.tmf.core.event.ITmfEventField; */ public class CustomXmlEventType extends CustomEventType { - /** - * Constructor - * - * @param definition - * Trace definition - * @deprecated Use {@link #CustomXmlEventType(String, ITmfEventField)} - * instead. - */ - @Deprecated - public CustomXmlEventType(CustomXmlTraceDefinition definition) { - super(definition); - } - /** * Constructor * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputAttribute.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputAttribute.java index 5bbb8848a8..6fbc5433a7 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputAttribute.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputAttribute.java @@ -34,31 +34,6 @@ public final class CustomXmlInputAttribute { /** Input format */ private final String fInputFormat; - /** - * Constructor - * - * @param attributeName - * Name of the XML attribute - * @param inputName - * Input name - * @param inputAction - * Input action - * @param inputFormat - * Input format - * @deprecated Use - * {@link #CustomXmlInputAttribute(String, Tag, String, int, String)} - * instead. - */ - @Deprecated - public CustomXmlInputAttribute(String attributeName, String inputName, - int inputAction, String inputFormat) { - fAttributeName = attributeName; - fInputTag = Tag.IGNORE; - fInputName = inputName; - fInputAction = inputAction; - fInputFormat = inputFormat; - } - /** * Constructor * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputElement.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputElement.java index 2092101338..15e80b6576 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputElement.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlInputElement.java @@ -62,37 +62,6 @@ public final class CustomXmlInputElement { public CustomXmlInputElement() { } - /** - * Constructor - * - * @param elementName - * Element name - * @param logEntry - * If this element is a log entry - * @param inputName - * Name of the input - * @param inputAction - * Input action - * @param inputFormat - * Input format - * @param attributes - * XML attributes of this element - * @deprecated Use - * {@link #CustomXmlInputElement(String, boolean, Tag, String, int, String, List)} - * instead. - */ - @Deprecated - public CustomXmlInputElement(String elementName, boolean logEntry, - String inputName, int inputAction, String inputFormat, - List attributes) { - fElementName = elementName; - fLogEntry = logEntry; - fInputName = inputName; - fInputAction = inputAction; - fInputFormat = inputFormat; - fAttributes = attributes; - } - /** * Constructor * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTrace.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTrace.java index 8e25ef5afd..5bed793176 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTrace.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTrace.java @@ -714,7 +714,7 @@ public class CustomXmlTrace extends TmfTrace implements ITmfPersistentlyIndexabl } /** - * @since 2.4 + * @since 3.0 */ @Override public synchronized ITmfTimestamp readEnd() { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTraceDefinition.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTraceDefinition.java index 7b28785e71..2eadc464e1 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTraceDefinition.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/parsers/custom/CustomXmlTraceDefinition.java @@ -61,11 +61,6 @@ import org.xml.sax.SAXParseException; */ public class CustomXmlTraceDefinition extends CustomTraceDefinition { - /** Ignore tag - * @deprecated Use {@link org.eclipse.tracecompass.tmf.core.parsers.custom.CustomTraceDefinition.Tag#IGNORE} instead. */ - @Deprecated - public static final String TAG_IGNORE = Messages.CustomXmlTraceDefinition_ignoreTag; - /** * Custom XML label used internally and therefore should not be externalized */ diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TmfTraceType.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TmfTraceType.java index a486c9bfe2..8ebd8d899b 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TmfTraceType.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TmfTraceType.java @@ -21,7 +21,6 @@ import java.util.Collections; import java.util.Comparator; import java.util.HashMap; import java.util.LinkedHashMap; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Map.Entry; @@ -129,63 +128,6 @@ public final class TmfTraceType { // Operations // ------------------------------------------------------------------ - /** - * Retrieves the category name from the platform extension registry based on - * the category ID - * - * @param categoryId - * The category ID - * @return the category name or empty string if not found - * @deprecated Use {@link Platform#getExtensionRegistry()} and various - * public constants in {@link TmfTraceType} if achieving this is - * needed. - */ - @Deprecated - public static String getCategoryName(String categoryId) { - IConfigurationElement[] elements = Platform.getExtensionRegistry() - .getConfigurationElementsFor(TMF_TRACE_TYPE_ID); - for (IConfigurationElement element : elements) { - if (element.getName().equals(CATEGORY_ELEM) && element.getAttribute(ID_ATTR).equals(categoryId)) { - return element.getAttribute(NAME_ATTR); - } - } - return ""; //$NON-NLS-1$ - } - - /** - * Retrieves all configuration elements from the platform extension registry - * for the trace type extension that apply to traces and not experiments. - * - * @return an array of trace type configuration elements - * @deprecated Use {@link Platform#getExtensionRegistry()} and various - * public constants in {@link TmfTraceType} if achieving this is - * needed. - */ - @Deprecated - public static IConfigurationElement[] getTypeElements() { - IConfigurationElement[] elements = Platform.getExtensionRegistry() - .getConfigurationElementsFor(TMF_TRACE_TYPE_ID); - List typeElements = new LinkedList<>(); - for (IConfigurationElement element : elements) { - if (element.getName().equals(TYPE_ELEM)) { - typeElements.add(element); - } - } - return typeElements.toArray(new IConfigurationElement[typeElements.size()]); - } - - /** - * Get an iterable view of the existing trace type IDs. - * - * @return The currently registered trace type IDs - * @deprecated Use a combination of {@link #getTraceTypeHelpers()} and - * {@link TraceTypeHelper#getTraceTypeId()} instead. - */ - @Deprecated - public static Iterable getTraceTypeIDs() { - return TRACE_TYPES.keySet(); - } - /** * Get an iterable view of the existing trace type helpers. * @@ -238,29 +180,6 @@ public final class TmfTraceType { return traceTypes.toArray(new String[traceTypes.size()]); } - /** - * Gets all the custom trace types - * - * @return the list of custom trace types - * @deprecated Use {@link CustomTxtTraceDefinition#loadAll()} and - * {@link CustomXmlTraceDefinition#loadAll()} if achieving this - * is needed. - */ - @Deprecated - public static List getCustomTraceTypes() { - - List traceTypes = new ArrayList<>(); - for (CustomTxtTraceDefinition def : CustomTxtTraceDefinition.loadAll()) { - String traceTypeName = def.definitionName; - traceTypes.add(traceTypeName); - } - for (CustomXmlTraceDefinition def : CustomXmlTraceDefinition.loadAll()) { - String traceTypeName = def.definitionName; - traceTypes.add(traceTypeName); - } - return traceTypes; - } - private static void populateCustomTraceTypes() { // add the custom trace types for (CustomTxtTraceDefinition def : CustomTxtTraceDefinition.loadAll()) { @@ -434,89 +353,6 @@ public final class TmfTraceType { return ""; //$NON-NLS-1$ } - /** - * Returns the list of trace categories - * - * @return the list of trace categories - * @deprecated Use {@link #getTraceTypeHelpers()} and - * {@link TraceTypeHelper#getCategoryName()} to retrieve all - * category names. - */ - @Deprecated - public static List getTraceCategories() { - List categoryNames = new ArrayList<>(); - for (TraceTypeHelper helper : TRACE_TYPES.values()) { - final String categoryName = helper.getCategoryName(); - if (!categoryNames.contains(categoryName)) { - categoryNames.add(categoryName); - } - } - return categoryNames; - } - - /** - * Get the trace type helper classes from category name. Return only the - * trace types, not the experiment types - * - * @param categoryName - * the categoryName to lookup - * @return a list of trace type helper classes {@link TraceTypeHelper} - * @deprecated Use {@link #getTraceTypeHelpers()} and - * {@link TraceTypeHelper#getCategoryName()} to retrieve all - * category names. - */ - @Deprecated - public static List getTraceTypes(String categoryName) { - List traceNames = new ArrayList<>(); - for (TraceTypeHelper traceTypeHelper : TRACE_TYPES.values()) { - if (!traceTypeHelper.isExperimentType()) { - final String storedCategoryName = traceTypeHelper.getCategoryName(); - if (storedCategoryName.equals(categoryName)) { - traceNames.add(traceTypeHelper); - } - } - } - return traceNames; - } - - /** - * Validate a trace type - * - * @param traceTypeName - * the trace category (canonical name) - * @param fileName - * the file name (and path) - * @return true if the trace is of a valid type - * @deprecated Use TmfTraceType.getTraceTypeHelpers and - * {@link TraceTypeHelper#validate(String)} or - * {@link TraceTypeHelper#validateWithConfidence(String)} - */ - @Deprecated - public static boolean validate(String traceTypeName, String fileName) { - if (traceTypeName != null && !traceTypeName.isEmpty()) { - final TraceTypeHelper traceTypeHelper = TRACE_TYPES.get(traceTypeName); - if (traceTypeHelper == null || !traceTypeHelper.validate(fileName).isOK()) { - return false; - } - } - return true; - } - - /** - * Validate a trace - * - * @param traceToValidate - * the trace category (canonical name) - * @return true if the trace is of a valid type - * @deprecated Use TmfTraceType.getTraceTypeHelpers and - * {@link TraceTypeHelper#validate(String)} or - * {@link TraceTypeHelper#validateWithConfidence(String)} - */ - @Deprecated - public static boolean validate(TraceValidationHelper traceToValidate) { - return validate(traceToValidate.getTraceType(), traceToValidate.getTraceToScan()); - } - /** * Get a configuration element for a given name * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypeHelper.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypeHelper.java index 4ae8d6ee4b..7ea609cba2 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypeHelper.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypeHelper.java @@ -175,7 +175,7 @@ public class TraceTypeHelper { * preferences or not * * @return True if the trace helper is enabled, false otherwise - * @since 2.4 + * @since 3.0 */ public boolean isEnabled() { return fEnable; @@ -186,7 +186,7 @@ public class TraceTypeHelper { * * @param enable * the new enable state - * @since 2.4 + * @since 3.0 */ public void setEnabled(boolean enable) { fEnable = enable; diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypePreferences.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypePreferences.java index 592d2ee965..041fbc2f90 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypePreferences.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceTypePreferences.java @@ -25,8 +25,7 @@ import com.google.common.collect.Lists; * trace type preferences is a blacklist preference of disabled trace types. * * @author Jean-Christian Kouame - * @since 2.4 - * + * @since 3.0 */ public final class TraceTypePreferences { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceValidationHelper.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceValidationHelper.java deleted file mode 100644 index 29ce22be8f..0000000000 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/project/model/TraceValidationHelper.java +++ /dev/null @@ -1,96 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2013, 2014 Ericsson - * - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Matthew Khouzam - Initial API and implementation - *******************************************************************************/ - -package org.eclipse.tracecompass.tmf.core.project.model; - -import java.util.Objects; - -/** - * Trace import helper class - * - * @author Matthew Khouzam - * @deprecated Use TmfTraceType.getTraceTypeHelpers and - * {@link TraceTypeHelper#validate(String)} or - * {@link TraceTypeHelper#validateWithConfidence(String)} - */ -@Deprecated -public class TraceValidationHelper implements Comparable { - - private final String fTraceToScan; - private final String fTraceType; - - /** - * Trace To validate constructor - * - * @param traceToScan - * the path of the trace - * @param traceType - * the trace type of the trace to add (canonical name) - */ - public TraceValidationHelper(String traceToScan, String traceType) { - this.fTraceToScan = traceToScan; - this.fTraceType = traceType; - } - - /** - * @return the trace filename - */ - public String getTraceToScan() { - return fTraceToScan; - } - - /** - * @return the trace type canonical name - */ - public String getTraceType() { - return fTraceType; - } - - @Override - public int hashCode() { - final int prime = 31; - int result = 1; - result = prime * result + ((fTraceToScan == null) ? 0 : fTraceToScan.hashCode()); - result = prime * result + ((fTraceType == null) ? 0 : fTraceType.hashCode()); - return result; - } - - @Override - public boolean equals(Object obj) { - if (this == obj) { - return true; - } - if (obj == null) { - return false; - } - if (!(obj instanceof TraceValidationHelper)) { - return false; - } - TraceValidationHelper other = (TraceValidationHelper) obj; - if (!Objects.equals(fTraceToScan, other.fTraceToScan)) { - return false; - } - if(!Objects.equals(fTraceType, other.fTraceType)){ - return false; - } - return true; - } - - @Override - public int compareTo(TraceValidationHelper o) { - int retVal = fTraceToScan.compareTo(o.getTraceToScan()); - if (retVal == 0) { - retVal = fTraceType.compareTo(o.fTraceType); - } - return retVal; - } -} \ No newline at end of file diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/AbstractTmfStateProvider.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/AbstractTmfStateProvider.java index 998c1ddcfe..ee3afe714e 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/AbstractTmfStateProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/AbstractTmfStateProvider.java @@ -184,7 +184,7 @@ public abstract class AbstractTmfStateProvider implements ITmfStateProvider { } /** - * @since 2.4 + * @since 3.0 */ @Override public void fail(Throwable cause) { @@ -192,7 +192,7 @@ public abstract class AbstractTmfStateProvider implements ITmfStateProvider { } /** - * @since 2.4 + * @since 3.0 */ @Override public @Nullable Throwable getFailureCause() { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/ITmfStateProvider.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/ITmfStateProvider.java index aec2f91181..f24f8862db 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/ITmfStateProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/statesystem/ITmfStateProvider.java @@ -123,7 +123,7 @@ public interface ITmfStateProvider { * Makes the state provider fail with a cause * * @param cause The cause of the failure - * @since 2.4 + * @since 3.0 */ default void fail(Throwable cause) { // Do nothing by default. @@ -133,7 +133,7 @@ public interface ITmfStateProvider { * Get the cause of failure, or null if there is no failure. * * @return The failure cause - * @since 2.4 + * @since 3.0 */ default @Nullable Throwable getFailureCause() { return null; diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/DefaultSymbolProvider.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/DefaultSymbolProvider.java index 9d9676a838..72bdf5226f 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/DefaultSymbolProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/DefaultSymbolProvider.java @@ -19,7 +19,7 @@ import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; * format representation of the symbol address * * @author Robert Kiss - * @since 2.4 + * @since 3.0 */ public class DefaultSymbolProvider implements ISymbolProvider { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProvider.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProvider.java index a4569479f0..bdf43f414e 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProvider.java @@ -20,7 +20,7 @@ import org.eclipse.tracecompass.tmf.core.trace.TmfTrace; * * @author Matthew Khouzam * @author Robert Kiss - * @since 2.4 + * @since 3.0 */ public interface ISymbolProvider { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProviderFactory.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProviderFactory.java index b35ee47b44..16c52711af 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProviderFactory.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/ISymbolProviderFactory.java @@ -19,7 +19,7 @@ import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; * * @author Robert Kiss * - * @since 2.4 + * @since 3.0 */ public interface ISymbolProviderFactory { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/SymbolProviderManager.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/SymbolProviderManager.java index 6d17ff15f4..bf638f0ae5 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/SymbolProviderManager.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/symbols/SymbolProviderManager.java @@ -31,7 +31,7 @@ import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; * point. * * @author Robert Kiss - * @since 2.4 + * @since 3.0 */ public final class SymbolProviderManager { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/timestamp/TmfTimestamp.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/timestamp/TmfTimestamp.java index 8fdb9d1ccc..104cad4728 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/timestamp/TmfTimestamp.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/timestamp/TmfTimestamp.java @@ -422,27 +422,6 @@ public abstract class TmfTimestamp implements ITmfTimestamp { return ts.getValue() == nts.getValue() && ts.getScale() == nts.getScale(); } - /** - * Saturated addition. It will not overflow but instead clamp the result to - * {@link Long#MAX_VALUE} and {@link Long#MIN_VALUE}. - * - * @param left - * The left long to add - * @param right - * The right long to add - * @return The saturated addition result. The mathematical, not Java version - * of Min(Max(MIN_VALUE, left+right), MAX_VALUE). - * @see - * Saturation arithmetic - * @since 2.0 - * @deprecated use {@link SaturatedArithmetic#add(long, long)} instead - */ - @Deprecated - protected static final long saturatedAdd(final long left, final long right) { - return SaturatedArithmetic.add(left, right); - } - - // ------------------------------------------------------------------------ // Object // ------------------------------------------------------------------------ diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ICyclesConverter.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ICyclesConverter.java index 3d07772fe9..7307787cb5 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ICyclesConverter.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ICyclesConverter.java @@ -16,7 +16,7 @@ package org.eclipse.tracecompass.tmf.core.trace; * An adapter interface for traces, which allows the trace to provide conversion * functions between cycles and nanoseconds. * - * @since 2.4 + * @since 3.0 */ public interface ICyclesConverter { diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ITmfTrace.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ITmfTrace.java index e697b05b75..2d79e334c1 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ITmfTrace.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/ITmfTrace.java @@ -453,7 +453,7 @@ public interface ITmfTrace extends ITmfEventProvider { * indexed. * * @return the trace's start time. Null if the trace is empty or failed. - * @since 2.4 + * @since 3.0 */ default ITmfTimestamp readStart() { ITmfContext context = seekEvent(0L); @@ -467,7 +467,7 @@ public interface ITmfTrace extends ITmfEventProvider { * indexed. * * @return the trace's end time. Null if the trace is empty or failed. - * @since 2.4 + * @since 3.0 */ default ITmfTimestamp readEnd() { /* diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTrace.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTrace.java index d94462c9b8..13afbb9620 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTrace.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTrace.java @@ -41,7 +41,6 @@ import org.eclipse.tracecompass.tmf.core.component.ITmfEventProvider; import org.eclipse.tracecompass.tmf.core.component.TmfEventProvider; import org.eclipse.tracecompass.tmf.core.event.ITmfEvent; import org.eclipse.tracecompass.tmf.core.event.ITmfLostEvent; -import org.eclipse.tracecompass.tmf.core.event.TmfEvent; import org.eclipse.tracecompass.tmf.core.event.aspect.ITmfEventAspect; import org.eclipse.tracecompass.tmf.core.event.aspect.TmfBaseAspects; import org.eclipse.tracecompass.tmf.core.exceptions.TmfAnalysisException; @@ -563,18 +562,6 @@ public abstract class TmfTrace extends TmfEventProvider implements ITmfTrace, IT return event; } - /** - * Update the trace attributes - * - * @param context the current trace context - * @param timestamp the corresponding timestamp - * @deprecated Use {@link #updateAttributes(ITmfContext, ITmfEvent)} - */ - @Deprecated - protected synchronized void updateAttributes(final ITmfContext context, final @NonNull ITmfTimestamp timestamp) { - updateAttributes(context, new TmfEvent(this, context.getRank(), timestamp, null, null)); - } - /** * Update the trace attributes * @@ -741,7 +728,7 @@ public abstract class TmfTrace extends TmfEventProvider implements ITmfTrace, IT //TODO: Move to ITmfTrace as default method when Bug 507246 is fixed /** - * @since 2.4 + * @since 3.0 */ @SuppressWarnings("unchecked") @Override diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceContext.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceContext.java index 2a663e421b..29d8a4ad9f 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceContext.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceContext.java @@ -122,38 +122,6 @@ public class TmfTraceContext implements ITraceContextSignalHandler { return fFilter; } - /** - * Store a data for the trace - * - * @param key - * The id of the data - * @param value - * The value of the data - * @since 2.1 - * @deprecated Use - * {@link TmfTraceManager#updateTraceContext(ITmfTrace, java.util.function.UnaryOperator)} - * and apply {@link Builder#setData(String, Object)} instead. - */ - @Deprecated - public synchronized void setData(String key, Object value) { - fData.put(key, value); - } - - /** - * Copy data into the data map - * - * @param data - * The map of data to copy - * @since 2.1 - * @deprecated Use - * {@link TmfTraceManager#updateTraceContext(ITmfTrace, java.util.function.UnaryOperator)} - * and apply {@link Builder#setData(Map)} instead. - */ - @Deprecated - public synchronized void setData(Map data) { - fData.putAll(data); - } - /** * Get the data for the specific key * diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceUtils.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceUtils.java index b38a3ce7c0..70fbd5a4de 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceUtils.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/TmfTraceUtils.java @@ -86,7 +86,7 @@ public final class TmfTraceUtils { * * @param aspect * The event aspect to register - * @since 2.4 + * @since 3.0 */ public static void registerEventAspect(ITmfEventAspect aspect) { EXTRA_ASPECTS.add(aspect); @@ -169,7 +169,7 @@ public final class TmfTraceUtils { * @return The first result of the * {@link ITmfEventAspect#resolve(ITmfEvent)} that returns non null * for the event or {@code null} otherwise - * @since 2.4 + * @since 3.0 */ public static @Nullable Object resolveAspectOfNameForEvent(ITmfTrace trace, String aspectName, ITmfEvent event) { // First look in the trace aspects diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/experiment/TmfExperiment.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/experiment/TmfExperiment.java index 5ac6a2ed58..0f92bd13c7 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/experiment/TmfExperiment.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/experiment/TmfExperiment.java @@ -85,17 +85,6 @@ public class TmfExperiment extends TmfTrace implements ITmfPersistentlyIndexable // Constants // ------------------------------------------------------------------------ - /** - * The file name of the Synchronization - * - * @deprecated This file name shouldn't be used directly anymore. All - * synchronization files have been moved to a folder and you - * should use the {@link #getSynchronizationFolder(boolean)} - * method to return the path to this folder. - */ - @Deprecated - public static final String SYNCHRONIZATION_FILE_NAME = "synchronization.bin"; //$NON-NLS-1$ - /** * The name of the directory containing trace synchronization data. This * directory typically will be preserved when traces are synchronized. @@ -625,7 +614,7 @@ public class TmfExperiment extends TmfTrace implements ITmfPersistentlyIndexable try { String syncDirectory = getSynchronizationFolder(true); - final File syncFile = (syncDirectory != null) ? new File(syncDirectory + File.separator + SYNCHRONIZATION_FILE_NAME) : null; + final File syncFile = (syncDirectory != null) ? new File(syncDirectory + File.separator + getSynchronizationFolder(true)) : null; final SynchronizationAlgorithm syncAlgo = SynchronizationManager.synchronizeTraces(syncFile, Collections.singleton(this), doSync); diff --git a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/text/TextTrace.java b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/text/TextTrace.java index 6ce26c7332..a6b5b5e01f 100644 --- a/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/text/TextTrace.java +++ b/tmf/org.eclipse.tracecompass.tmf.core/src/org/eclipse/tracecompass/tmf/core/trace/text/TextTrace.java @@ -435,7 +435,7 @@ public abstract class TextTrace extends TmfTrace imple } /** - * @since 2.4 + * @since 3.0 */ @Override public synchronized ITmfTimestamp readEnd() { diff --git a/tmf/org.eclipse.tracecompass.tmf.ui.swtbot.tests/shared/org/eclipse/tracecompass/tmf/ui/swtbot/tests/shared/SWTBotUtils.java b/tmf/org.eclipse.tracecompass.tmf.ui.swtbot.tests/shared/org/eclipse/tracecompass/tmf/ui/swtbot/tests/shared/SWTBotUtils.java index 6decea2e77..73a057c678 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui.swtbot.tests/shared/org/eclipse/tracecompass/tmf/ui/swtbot/tests/shared/SWTBotUtils.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui.swtbot.tests/shared/org/eclipse/tracecompass/tmf/ui/swtbot/tests/shared/SWTBotUtils.java @@ -131,20 +131,6 @@ public final class SWTBotUtils { private static final String TRACING_PERSPECTIVE_ID = TracingPerspectiveFactory.ID; - /** - * Waits for all Eclipse jobs to finish. Times out after - * WaitUtils#MAX_JOBS_WAIT_TIME by default. - * - * @throws RuntimeException - * once the waiting time passes the default maximum value - * - * @deprecated Use {@link WaitUtils#waitForJobs()} instead - */ - @Deprecated - public static void waitForJobs() { - WaitUtils.waitForJobs(); - } - /** * Sleeps current thread for a given time. * diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/META-INF/MANIFEST.MF b/tmf/org.eclipse.tracecompass.tmf.ui/META-INF/MANIFEST.MF index 5c8e98154f..c26d7a1ab1 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/META-INF/MANIFEST.MF +++ b/tmf/org.eclipse.tracecompass.tmf.ui/META-INF/MANIFEST.MF @@ -84,7 +84,6 @@ Export-Package: org.eclipse.tracecompass.internal.tmf.ui;x-friends:="org.eclipse org.eclipse.tracecompass.tmf.ui.viewers, org.eclipse.tracecompass.tmf.ui.viewers.events, org.eclipse.tracecompass.tmf.ui.viewers.events.columns, - org.eclipse.tracecompass.tmf.ui.viewers.events.text, org.eclipse.tracecompass.tmf.ui.viewers.table, org.eclipse.tracecompass.tmf.ui.viewers.tree, org.eclipse.tracecompass.tmf.ui.viewers.xycharts, diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/internal/tmf/ui/symbols/BasicSymbolProvider.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/internal/tmf/ui/symbols/BasicSymbolProvider.java index 3135a4e454..199d408413 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/internal/tmf/ui/symbols/BasicSymbolProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/internal/tmf/ui/symbols/BasicSymbolProvider.java @@ -18,8 +18,6 @@ import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.jdt.annotation.NonNull; import org.eclipse.jdt.annotation.Nullable; import org.eclipse.tracecompass.internal.tmf.core.callstack.FunctionNameMapper; -import org.eclipse.tracecompass.tmf.core.event.lookup.ITmfCallsite; -import org.eclipse.tracecompass.tmf.core.event.lookup.TmfCallsite; import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; import org.eclipse.tracecompass.tmf.ui.symbols.ISymbolProvider; import org.eclipse.tracecompass.tmf.ui.symbols.ISymbolProviderPreferencePage; @@ -138,17 +136,6 @@ public class BasicSymbolProvider implements ISymbolProvider { return fMapping.get(Long.toHexString(address)); } - @Deprecated - @Override - public @Nullable ITmfCallsite getSymbolInfo(long address) { - loadConfiguration(null); - String symbolText = getSymbolText(address); - if (symbolText != null) { - return new TmfCallsite(null, symbolText, -1); - } - return null; - } - @Override public ISymbolProviderPreferencePage createPreferencePage() { return new BasicSymbolProviderPreferencePage(this); diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/DefaultSymbolProvider.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/DefaultSymbolProvider.java index 9c50b5e430..27c2080f40 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/DefaultSymbolProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/DefaultSymbolProvider.java @@ -14,7 +14,6 @@ import org.eclipse.core.runtime.IProgressMonitor; import org.eclipse.jdt.annotation.NonNull; import org.eclipse.jdt.annotation.NonNullByDefault; import org.eclipse.jdt.annotation.Nullable; -import org.eclipse.tracecompass.tmf.core.event.lookup.ITmfCallsite; import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace; /** @@ -66,19 +65,6 @@ public class DefaultSymbolProvider implements ISymbolProvider { return String.format("%016x", address); //$NON-NLS-1$ } - /** - * The default symbol provider will return null for this method - * - * @param address - * the symbol address - * @return always null - */ - @Deprecated - @Override - public @Nullable ITmfCallsite getSymbolInfo(long address) { - return null; - } - /** * @return null because the default symbol provider doesn't support * configuration diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/ISymbolProvider.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/ISymbolProvider.java index 202f393028..644a4399ce 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/ISymbolProvider.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/symbols/ISymbolProvider.java @@ -11,7 +11,6 @@ package org.eclipse.tracecompass.tmf.ui.symbols; import org.eclipse.jdt.annotation.Nullable; -import org.eclipse.tracecompass.tmf.core.event.lookup.ITmfCallsite; import org.eclipse.tracecompass.tmf.core.trace.TmfTrace; /** @@ -27,40 +26,6 @@ import org.eclipse.tracecompass.tmf.core.trace.TmfTrace; */ public interface ISymbolProvider extends org.eclipse.tracecompass.tmf.core.symbols.ISymbolProvider { - /** - * Return additional information regarding the symbol from the given address - * or null if the symbol cannot be found - * - * @param address - * the address of the symbol - * @return the symbol {@link ITmfCallsite} information or null if the symbol - * cannot be found - * @deprecated This interface should only provide function/symbol names, not - * full source locations. - */ - @Deprecated - @Nullable ITmfCallsite getSymbolInfo(long address); - - /** - * Return additional information regarding the symbol from the given - * pid/timestamp/address tuple, or null if the symbol cannot be found. - * - * @param pid - * The process Id for which to query - * @param timestamp - * The timestamp of the query - * @param address - * the address of the symbol - * @return the symbol {@link ITmfCallsite} information or null if the symbol - * cannot be found - * @deprecated This interface should only provide function/symbol names, not - * full source locations. - */ - @Deprecated - default @Nullable ITmfCallsite getSymbolInfo(int pid, long timestamp, long address) { - return getSymbolInfo(address); - } - /** * Create the {@link ISymbolProviderPreferencePage} that can be used to * configure this {@link ISymbolProvider} diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/TmfEventsTable.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/TmfEventsTable.java index 9e9cd72900..ba270df3a0 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/TmfEventsTable.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/TmfEventsTable.java @@ -134,7 +134,6 @@ import org.eclipse.tracecompass.tmf.core.component.ITmfEventProvider; import org.eclipse.tracecompass.tmf.core.component.TmfComponent; import org.eclipse.tracecompass.tmf.core.event.ITmfEvent; import org.eclipse.tracecompass.tmf.core.event.aspect.ITmfEventAspect; -import org.eclipse.tracecompass.tmf.core.event.aspect.TmfContentFieldAspect; import org.eclipse.tracecompass.tmf.core.event.collapse.ITmfCollapsibleEvent; import org.eclipse.tracecompass.tmf.core.event.lookup.ITmfCallsite; import org.eclipse.tracecompass.tmf.core.event.lookup.ITmfModelLookup; @@ -188,7 +187,6 @@ import org.eclipse.ui.themes.IThemeManager; import com.google.common.base.Joiner; import com.google.common.collect.HashMultimap; -import com.google.common.collect.ImmutableList; import com.google.common.collect.Multimap; /** @@ -787,43 +785,6 @@ public class TmfEventsTable extends TmfComponent implements IGotoMarker, IColorS this(parent, cacheSize, TmfTrace.BASE_ASPECTS); } - /** - * Legacy constructor, using ColumnData to define columns - * - * @param parent - * The parent composite UI object - * @param cacheSize - * The size of the event table cache - * @param columnData - * The column data array - * @deprecated Deprecated constructor, use - * {@link #TmfEventsTable(Composite, int, Collection)} - */ - @Deprecated - public TmfEventsTable(final Composite parent, int cacheSize, - final org.eclipse.tracecompass.tmf.ui.widgets.virtualtable.ColumnData[] columnData) { - /* - * We'll do a "best-effort" to keep trace types still using this API to - * keep working, by defining a TmfEventTableColumn for each ColumnData - * they passed. - */ - this(parent, cacheSize, convertFromColumnData(columnData)); - } - - @Deprecated - private static @NonNull Iterable> convertFromColumnData( - org.eclipse.tracecompass.tmf.ui.widgets.virtualtable.ColumnData[] columnData) { - - ImmutableList.Builder> builder = new ImmutableList.Builder<>(); - for (org.eclipse.tracecompass.tmf.ui.widgets.virtualtable.ColumnData col : columnData) { - String fieldName = col.header; - if (fieldName != null) { - builder.add(new TmfContentFieldAspect(fieldName, fieldName)); - } - } - return builder.build(); - } - /** * Standard constructor, where we define which columns to use. * @@ -1580,17 +1541,6 @@ public class TmfEventsTable extends TmfComponent implements IGotoMarker, IColorS return fTable; } - /** - * @param columnData - * columnData - * @deprecated The column headers are now set at the constructor, this - * shouldn't be called anymore. - */ - @Deprecated - protected void setColumnHeaders(final org.eclipse.tracecompass.tmf.ui.widgets.virtualtable.ColumnData[] columnData) { - /* No-op */ - } - /** * Set a table item's data. * diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/text/TmfTextEventTable.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/text/TmfTextEventTable.java deleted file mode 100644 index 597c485c03..0000000000 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/viewers/events/text/TmfTextEventTable.java +++ /dev/null @@ -1,69 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2014 Ericsson - * - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Alexandre Montplaisir - Initial API and implementation - *******************************************************************************/ - -package org.eclipse.tracecompass.tmf.ui.viewers.events.text; - -import java.util.List; - -import org.eclipse.swt.widgets.Composite; -import org.eclipse.tracecompass.tmf.core.event.ITmfEvent; -import org.eclipse.tracecompass.tmf.core.trace.text.TextTraceEvent; -import org.eclipse.tracecompass.tmf.core.trace.text.TextTraceEventContent; -import org.eclipse.tracecompass.tmf.ui.viewers.events.TmfEventsTable; -import org.eclipse.tracecompass.tmf.ui.widgets.virtualtable.ColumnData; - -/** - * Event table for text traces, which has one column for every event field. - * - * @author Alexandre Montplaisir - * @deprecated Users of this class should instead use - * {@link TmfEventsTable#TmfEventsTable(Composite, int, java.util.Collection)} - * , by passing - * {@link org.eclipse.tracecompass.tmf.ui.viewers.events.columns.TmfEventTableColumn} - * . - */ -@Deprecated -public class TmfTextEventTable extends TmfEventsTable { - - /** - * Constructor - * - * @param parent - * The parent composite UI object - * @param cacheSize - * The size of the event table cache - * @param columnData - * The column data to use for this table - */ - public TmfTextEventTable(Composite parent, int cacheSize, ColumnData[] columnData) { - super(parent, cacheSize, columnData); - } - - /** - * @param event - * The event to get the column strings for. It should be an - * instance of {@link TextTraceEvent}. - */ - @Override - public String[] getItemStrings(ITmfEvent event) { - if (event instanceof TextTraceEvent) { - List fields = ((TextTraceEvent) event).getContent().getFields(); - String[] strings = new String[fields.size()]; - for (int i = 0; i < strings.length; i++) { - Object value = fields.get(i).getValue(); - strings[i] = (value == null ? EMPTY_STRING : value.toString()); - } - return strings; - } - return EMPTY_STRING_ARRAY; - } -} diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/AbstractCallStackAnalysis.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/AbstractCallStackAnalysis.java deleted file mode 100644 index 665162d7d2..0000000000 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/AbstractCallStackAnalysis.java +++ /dev/null @@ -1,39 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2014, 2016 Ericsson - * - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Alexandre Montplaisir - Initial API and implementation - * Patrick Tasse - Add methods to get attribute paths - *******************************************************************************/ - -package org.eclipse.tracecompass.tmf.ui.views.callstack; - -import org.eclipse.jdt.annotation.NonNullByDefault; -import org.eclipse.tracecompass.tmf.core.callstack.CallStackAnalysis; -import org.eclipse.tracecompass.tmf.ui.analysis.TmfAnalysisViewOutput; - -/** - * The base classes for analyses who want to populate the CallStack View. - * - * @author Alexandre Montplaisir - * @deprecated Use the {@link CallStackAnalysis} from the core plugins instead - * of this class which was there only to register the view as output - */ -@Deprecated -@NonNullByDefault -public abstract class AbstractCallStackAnalysis extends CallStackAnalysis { - - /** - * Abstract constructor (should only be called via the sub-classes' - * constructors. - */ - protected AbstractCallStackAnalysis() { - super(); - registerOutput(new TmfAnalysisViewOutput(CallStackView.ID)); - } -} diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/CallStackEntry.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/CallStackEntry.java index 74a5f5dee6..6c2c90c250 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/CallStackEntry.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/views/callstack/CallStackEntry.java @@ -35,50 +35,6 @@ public class CallStackEntry extends TimeGraphEntry { private long fFunctionExitTime; private @NonNull ITmfStateSystem fSS; - /** - * Standard constructor - * - * @param quark - * The call stack quark - * @param stackLevel - * The stack level - * @param trace - * The trace that this view is talking about - * @deprecated Use {@link #CallStackEntry(String, int, int, int, ITmfTrace, ITmfStateSystem)} - */ - @Deprecated - public CallStackEntry(int quark, int stackLevel, ITmfTrace trace) { - super(null, 0, 0); - throw new UnsupportedOperationException(); - } - - /** - * Standard constructor - * - * @param name - * The parent thread name - * @param quark - * The call stack quark - * @param stackLevel - * The stack level - * @param trace - * The trace that this view is talking about - * @param ss - * The call stack state system - * @deprecated Use - * {@link #CallStackEntry(String, int, int, int, ITmfTrace, ITmfStateSystem)} - */ - @Deprecated - public CallStackEntry(String name, int quark, int stackLevel, ITmfTrace trace, @NonNull ITmfStateSystem ss) { - super(name, 0, 0); - fQuark = quark; - fStackLevel = stackLevel; - fProcessId = -1; - fTrace = trace; - fFunctionName = ""; //$NON-NLS-1$ - fSS = ss; - } - /** * Standard constructor * @@ -122,26 +78,6 @@ public class CallStackEntry extends TimeGraphEntry { fFunctionName = functionName; } - /** - * Set the start time of the call stack entry - * @param startTime the start time - * @deprecated Use {@link #setFunctionEntryTime(long)} - */ - @Deprecated - public void setStartTime(long startTime) { - throw new UnsupportedOperationException(); - } - - /** - * Set the end time of the call stack entry - * @param endTime the end time - * @deprecated Use {@link #setFunctionExitTime(long)} - */ - @Deprecated - public void setEndTime(long endTime) { - throw new UnsupportedOperationException(); - } - /** * Set the selected function entry time * diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/TimeGraphViewer.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/TimeGraphViewer.java index e741579a38..315732be79 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/TimeGraphViewer.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/TimeGraphViewer.java @@ -1527,18 +1527,6 @@ public class TimeGraphViewer extends Viewer implements ITimeDataProvider, IMarke setSelectedTimeInt(time, true, true); } - /** - * Sets a new selection for this viewer and makes it visible. - * - * @param entry - * The entry to select - * @deprecated Use {@link #setSelection(ISelection, boolean)} instead. - */ - @Deprecated - public void setSelection(ITimeGraphEntry entry) { - setSelection(entry, true); - } - @Override public void setSelection(ISelection selection, boolean reveal) { /* if there is a pending selection, ignore this one */ diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/TimeGraphSelection.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/TimeGraphSelection.java deleted file mode 100644 index 9df95df461..0000000000 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/TimeGraphSelection.java +++ /dev/null @@ -1,100 +0,0 @@ -/***************************************************************************** - * Copyright (c) 2007, 2016 Intel Corporation, Ericsson - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Intel Corporation - Initial API and implementation - * Ruslan A. Scherbakov, Intel - Initial API and implementation - * Alvaro Sanchez-Leon - Updated for TMF - * Patrick Tasse - Refactoring - *****************************************************************************/ - -package org.eclipse.tracecompass.tmf.ui.widgets.timegraph.widgets; - -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; - -import org.eclipse.jface.viewers.IStructuredSelection; -import org.eclipse.jface.viewers.StructuredSelection; - -/** - * Selection object for the time graph scale - * - * @version 1.0 - * @author Alvaro Sanchez-Leon - * @author Patrick Tasse - * @deprecated Use {@link StructuredSelection} instead. - */ -@Deprecated -public class TimeGraphSelection implements IStructuredSelection { - - private List list = new ArrayList<>(); - - /** - * Default constructor - */ - public TimeGraphSelection() { - } - - /** - * "Wrapper" constructor. Instantiate a new selection object with only one - * existing selection. - * - * @param sel - * The initial selection to add to this one - */ - public TimeGraphSelection(Object sel) { - if (sel != null) { - list.add(sel); - } - } - - /** - * Add a selection to this one. - * - * @param sel - * The selection to add - */ - public void add(Object sel) { - if (null != sel && !list.contains(sel)) { - list.add(sel); - } - } - - @Override - public Object getFirstElement() { - if (!list.isEmpty()) { - return list.get(0); - } - return null; - } - - @Override - public Iterator iterator() { - return list.iterator(); - } - - @Override - public int size() { - return list.size(); - } - - @Override - public Object[] toArray() { - return list.toArray(); - } - - @Override - public List toList() { - return list; - } - - @Override - public boolean isEmpty() { - return list.isEmpty(); - } -} diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/Utils.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/Utils.java index f6b014d5e9..36dc984b29 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/Utils.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/timegraph/widgets/Utils.java @@ -320,54 +320,6 @@ public class Utils { return size.x; } - /** - * Draw text in a rectangle, trimming the text to prevent exceeding the specified width. - * - * @param gc - * The SWT GC object - * @param text - * The string to be drawn - * @param x - * The x coordinate of the top left corner of the rectangular area where the text is to be drawn - * @param y - * The y coordinate of the top left corner of the rectangular area where the text is to be drawn - * @param width - * The width of the area to be drawn - * @param isCentered - * If true the text will be centered in the available width if space permits - * @param isTransparent - * If true the background will be transparent, otherwise it will be opaque - * @return The number of characters written - * @deprecated Use {@link #drawText(GC, String, int, int, int, int, boolean, boolean)} instead. - */ - @Deprecated - public static int drawText(GC gc, String text, int x, int y, int width, boolean isCentered, boolean isTransparent) { - if (width < 1) { - return 0; - } - - int len = text.length(); - int textWidth = 0; - boolean isReallyCentered = isCentered; - int realX = x; - - while (len > 0) { - textWidth = gc.stringExtent(text.substring(0, len)).x; - if (textWidth <= width) { - break; - } - isReallyCentered = false; - len--; - } - if (len > 0) { - if (isReallyCentered) { - realX += (width - textWidth) / 2; - } - gc.drawText(text.substring(0, len), realX, y, isTransparent); - } - return len; - } - /** * Draw text in a rectangle, trimming the text to prevent exceeding the specified width. * diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/ColumnData.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/ColumnData.java deleted file mode 100644 index 84bf214fe8..0000000000 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/ColumnData.java +++ /dev/null @@ -1,48 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2010, 2014 Ericsson - * - * All rights reserved. This program and the accompanying materials are - * made available under the terms of the Eclipse Public License v1.0 which - * accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * Matthew Khouzam - Extracted from TmfEventsView - ******************************************************************************/ - -package org.eclipse.tracecompass.tmf.ui.widgets.virtualtable; - -/** - * ColumnData - * - * @author Matthew Khouzam - * @deprecated Use {@link org.eclipse.tracecompass.tmf.ui.viewers.events.columns.TmfEventTableColumn} instead. - */ -@Deprecated -public class ColumnData { - /** - * The title of the column - */ - public final String header; - /** - * the width of the column in pixels - */ - public final int width; - /** - * the alignment of the column - */ - public final int alignment; - - /** - * Constructor - * @param h header (title) - * @param w width - * @param a alignment - */ - public ColumnData(String h, int w, int a) { - header = h; - width = w; - alignment = a; - } - -} diff --git a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/TmfVirtualTable.java b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/TmfVirtualTable.java index d878e7e5f0..49c241f71a 100644 --- a/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/TmfVirtualTable.java +++ b/tmf/org.eclipse.tracecompass.tmf.ui/src/org/eclipse/tracecompass/tmf/ui/widgets/virtualtable/TmfVirtualTable.java @@ -1009,17 +1009,6 @@ public class TmfVirtualTable extends Composite { } } - /** - * Method setColumnHeaders. - * - * @param columnData - * ColumnData[] the columndata array. - */ - @Deprecated - public void setColumnHeaders(ColumnData columnData[]) { - /* No-op */ - } - /** * Method removeAll. * @return int 0 the number of elements in the table