--- /dev/null
+/*******************************************************************************
+ * Copyright (c) 2016 EfficiOS Inc., Alexandre Montplaisir
+ *
+ * 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
+ *******************************************************************************/
+
+package org.eclipse.tracecompass.internal.provisional.tmf.core.views.timegraph2;
+
+import java.util.List;
+import java.util.Set;
+
+import org.eclipse.core.runtime.IProgressMonitor;
+import org.eclipse.jdt.annotation.Nullable;
+import org.eclipse.tracecompass.tmf.core.trace.ITmfTrace;
+
+public interface ITimeGraphModelRenderProvider {
+
+ // ------------------------------------------------------------------------
+ // Configuration option classes
+ // ------------------------------------------------------------------------
+
+ class SortingMode {
+
+ private final String fName;
+
+ public SortingMode(String name) {
+ fName = name;
+ }
+
+ public String getName() {
+ return fName;
+ }
+ }
+
+ class FilterMode {
+
+ private final String fName;
+
+ public FilterMode(String name) {
+ fName = name;
+ }
+
+ public String getName() {
+ return fName;
+ }
+ }
+
+ // ------------------------------------------------------------------------
+ // Render generation methods
+ // ------------------------------------------------------------------------
+
+ default TimeGraphModelRender getRender(ITmfTrace trace,
+ long rangeStart, long rangeEnd, long resolution) {
+ return getRender(trace, rangeStart, rangeEnd, resolution, null);
+ }
+
+ TimeGraphModelRender getRender(ITmfTrace trace, long rangeStart, long rangeEnd,
+ long resolution, @Nullable IProgressMonitor monitor);
+
+ // ------------------------------------------------------------------------
+ // Sorting modes
+ // ------------------------------------------------------------------------
+
+ List<SortingMode> getSortingModes();
+
+ SortingMode getCurrentSortingMode();
+
+ void setCurrentSortingMode(int index);
+
+ // ------------------------------------------------------------------------
+ // Filter modes
+ // ------------------------------------------------------------------------
+
+ List<FilterMode> getFilterModes();
+
+ void enableFilterMode(int index);
+
+ void disableFilterMode(int index);
+
+ Set<FilterMode> getActiveFilterModes();
+
+ // ------------------------------------------------------------------------
+ // Other configuration options
+ // ------------------------------------------------------------------------
+
+ /**
+ * Set the time range configuration option. The timestamps should normally
+ * refer to a valid time range within the backing trace or other database.
+ * For GUI views it will usually refer to the visible time range of a
+ * zoomed-in viewport.
+ *
+ * This can then be used by other configuration options. For example, a
+ * filtering mode could be provided to filter out entries that do not change
+ * state within the configured time range.
+ *
+ * The implementation is free to ignore the configured time range if it does
+ * not provide anything special for it.
+ *
+ * @param startTime
+ * The start of the configured time range
+ * @param endTime
+ * The end of the configured time range.
+ */
+ void setConfiguredTimeRange(long startTime, long endTime);
+}