analysis: Move plugins to their own sub-directory
[deliverable/tracecompass.git] / org.eclipse.tracecompass.tmf.ui / src / org / eclipse / tracecompass / tmf / ui / widgets / timegraph / TimeGraphSelectionEvent.java
CommitLineData
be222f56 1/*******************************************************************************
ed902a2b 2 * Copyright (c) 2012, 2014 Ericsson
be222f56
PT
3 *
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
8 *
9 * Contributors:
10 * Patrick Tasse - Initial API and implementation
11 *******************************************************************************/
12
2bdf0193 13package org.eclipse.tracecompass.tmf.ui.widgets.timegraph;
be222f56
PT
14
15import java.util.EventObject;
16
2bdf0193 17import org.eclipse.tracecompass.tmf.ui.widgets.timegraph.model.ITimeGraphEntry;
be222f56
PT
18
19/**
20 * Notifier for the time graph that an object in the views has been selected.
21 *
be222f56
PT
22 * @author Patrick Tasse
23 */
24public class TimeGraphSelectionEvent extends EventObject {
25
26 /**
27 * Default serial version UID for this class.
be222f56
PT
28 */
29 private static final long serialVersionUID = 1L;
30
31 /**
32 * The selected entry.
33 */
34 private final ITimeGraphEntry fSelection;
35
36 /**
37 * Standard constructor
38 *
39 * @param source
40 * The source of this event
41 * @param selection
42 * The entry that was selected
43 */
44 public TimeGraphSelectionEvent(Object source, ITimeGraphEntry selection) {
45 super(source);
46 fSelection = selection;
47 }
48
49 /**
50 * @return the selected entry or null if the selection is empty.
51 */
52 public ITimeGraphEntry getSelection() {
53 return fSelection;
54 }
55
56}
This page took 0.066038 seconds and 5 git commands to generate.