Commit | Line | Data |
---|---|---|
8c8bf09f | 1 | /******************************************************************************* |
c392540b | 2 | * Copyright (c) 2009, 2011 Ericsson |
4f8ca6a1 | 3 | * |
8c8bf09f ASL |
4 | * All rights reserved. This program and the accompanying materials are |
5 | * made available under the terms of the Eclipse Public License v1.0 which | |
6 | * accompanies this distribution, and is available at | |
7 | * http://www.eclipse.org/legal/epl-v10.html | |
4f8ca6a1 | 8 | * |
8c8bf09f ASL |
9 | * Contributors: |
10 | * Francois Chouinard - Initial API and implementation | |
11 | *******************************************************************************/ | |
12 | ||
6c13869b | 13 | package org.eclipse.linuxtools.tmf.core.signal; |
8c8bf09f | 14 | |
4df4581d | 15 | import org.eclipse.linuxtools.tmf.core.event.ITmfTimestamp; |
6c13869b | 16 | import org.eclipse.linuxtools.tmf.core.event.TmfTimeRange; |
8c8bf09f ASL |
17 | |
18 | /** | |
4b7b3670 | 19 | * A new active time range has been selected |
4f8ca6a1 | 20 | * |
4b7b3670 FC |
21 | * @version 1.0 |
22 | * @author Francois Chouinard | |
8c8bf09f ASL |
23 | */ |
24 | public class TmfRangeSynchSignal extends TmfSignal { | |
25 | ||
c392540b | 26 | private final TmfTimeRange fCurrentRange; |
4df4581d | 27 | private final ITmfTimestamp fCurrentTime; |
8c8bf09f | 28 | |
4f8ca6a1 AM |
29 | /** |
30 | * Constructor | |
31 | * | |
32 | * @param source | |
33 | * Object sending this signal | |
34 | * @param range | |
35 | * The time range to which we synchronized | |
36 | * @param ts | |
37 | * The current selected timestamp, independent from the time | |
38 | * range | |
39 | */ | |
4df4581d | 40 | public TmfRangeSynchSignal(Object source, TmfTimeRange range, ITmfTimestamp ts) { |
c392540b FC |
41 | super(source); |
42 | fCurrentRange = range; | |
43 | fCurrentTime = ts; | |
44 | } | |
8c8bf09f | 45 | |
4f8ca6a1 AM |
46 | /** |
47 | * @return This signal's time range | |
48 | */ | |
c392540b FC |
49 | public TmfTimeRange getCurrentRange() { |
50 | return fCurrentRange; | |
51 | } | |
8c8bf09f | 52 | |
4f8ca6a1 AM |
53 | /** |
54 | * @return This signal's current selected timestamp | |
55 | */ | |
4df4581d | 56 | public ITmfTimestamp getCurrentTime() { |
c392540b FC |
57 | return fCurrentTime; |
58 | } | |
8c8bf09f ASL |
59 | |
60 | } |