2 /*****************************************************************************
3 * Copyright (c) 2007 Intel Corporation, 2010, 2012 Ericsson.
4 * All rights reserved. This program and the accompanying materials
5 * are made available under the terms of the Eclipse Public License v1.0
6 * which accompanies this distribution, and is available at
7 * http://www.eclipse.org/legal/epl-v10.html
10 * Intel Corporation - Initial API and implementation
11 * Ruslan A. Scherbakov, Intel - Initial API and implementation
12 * Alvaro Sanchez-Leon - Updated for TMF
13 * Patrick Tasse - Refactoring
15 *****************************************************************************/
17 package org
.eclipse
.linuxtools
.tmf
.ui
.widgets
.timegraph
.widgets
;
19 import org
.eclipse
.linuxtools
.tmf
.ui
.widgets
.timegraph
.widgets
.Utils
.TimeFormat
;
22 * Time data provider interface, for use in the timegraph widget.
25 * @author Alvaro Sanchez-Leon
26 * @author Patrick Tasse
27 * @author Xavier Raynaud
29 public interface ITimeDataProvider
{
32 * @return The selected time
34 long getSelectedTime();
37 * @return The beginning time
42 * @return The end time
47 * @return The minimum time
52 * @return The maximum time
57 * @return The start time of the current selection window
62 * @return The end time of the current selection window
67 * @return The minimal time interval
69 long getMinTimeInterval();
72 * Updates the time range and notify registered listeners
77 void setStartFinishTimeNotify(long time0
, long time1
);
80 * Update the time range but do not trigger event notification
85 void setStartFinishTime(long time0
, long time1
);
88 * Notify registered listeners without updating the time range
90 void notifyStartFinishTime();
93 * Updates the selected time, adjusts the time range if necessary and
94 * notifies any registered listeners about the new selected time and new
95 * range (if necessary)
99 * @param ensureVisible
100 * Ensure visibility of new time (will adjust time range if
103 public void setSelectedTimeNotify(long time
, boolean ensureVisible
);
106 * Updates the selected time and adjusts the time range if necessary without
107 * notifying registered listeners.
111 * @param ensureVisible
112 * Ensure visibility of new time (will adjust time range if
115 public void setSelectedTime(long time
, boolean ensureVisible
);
118 * Reset the start and end times
120 void resetStartFinishTime();
123 * @return The names' width
128 * Set the names' width
132 void setNameSpace(int width
);
135 * @return The width for timestamps
140 * @return the time format, one of:
142 * <li>{@link TimeFormat#CALENDAR} absolute time, displayed as year/month/day/hours/minutes/seconds/ms/us/ns
143 * <li>{@link TimeFormat#RELATIVE} relative time, displayed as seconds/ms/us/ns
144 * <li>{@link TimeFormat#NUMBER} number, displayed as long values.
148 TimeFormat
getTimeFormat();
This page took 0.049903 seconds and 6 git commands to generate.