tmf: Update copyright headers in tmf.ui
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.ui / src / org / eclipse / linuxtools / tmf / ui / project / wizards / SelectTracesWizard.java
1 /*******************************************************************************
2 * Copyright (c) 2009, 2012 Ericsson
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 * Francois Chouinard - Initial API and implementation
11 *******************************************************************************/
12
13 package org.eclipse.linuxtools.tmf.ui.project.wizards;
14
15 import org.eclipse.jface.viewers.IStructuredSelection;
16 import org.eclipse.jface.wizard.Wizard;
17 import org.eclipse.linuxtools.tmf.ui.project.model.TmfExperimentElement;
18 import org.eclipse.linuxtools.tmf.ui.project.model.TmfProjectElement;
19 import org.eclipse.ui.IImportWizard;
20 import org.eclipse.ui.IWorkbench;
21
22 /**
23 * Wizard implementation to select traces for an experiment.
24 * <p>
25 * @version 1.0
26 * @author Francois Chouinard
27 */
28 public class SelectTracesWizard extends Wizard implements IImportWizard {
29
30 // ------------------------------------------------------------------------
31 // Attributes
32 // ------------------------------------------------------------------------
33
34 private final TmfProjectElement fProject;
35 private final TmfExperimentElement fExperiment;
36 private SelectTracesWizardPage fSelectTraceWizardPage;
37
38 // ------------------------------------------------------------------------
39 // Constructor
40 // ------------------------------------------------------------------------
41 /**
42 * Constructor
43 * @param project The project model element
44 * @param experiment The experiemnt model element
45 */
46 public SelectTracesWizard(TmfProjectElement project, TmfExperimentElement experiment) {
47 fProject = project;
48 fExperiment = experiment;
49 }
50
51 // ------------------------------------------------------------------------
52 // Wizard
53 // ------------------------------------------------------------------------
54
55 /*
56 * (non-Javadoc)
57 * @see org.eclipse.ui.IWorkbenchWizard#init(org.eclipse.ui.IWorkbench, org.eclipse.jface.viewers.IStructuredSelection)
58 */
59 @Override
60 public void init(IWorkbench workbench, IStructuredSelection selection) {
61 setWindowTitle(Messages.SelectTracesWizard_WindowTitle);
62 }
63
64 /*
65 * (non-Javadoc)
66 * @see org.eclipse.jface.wizard.Wizard#addPages()
67 */
68 @Override
69 public void addPages() {
70 super.addPages();
71 fSelectTraceWizardPage = new SelectTracesWizardPage(fProject, fExperiment);
72 addPage(fSelectTraceWizardPage);
73 }
74
75 /*
76 * (non-Javadoc)
77 * @see org.eclipse.jface.wizard.Wizard#performFinish()
78 */
79 @Override
80 public boolean performFinish() {
81 return fSelectTraceWizardPage.performFinish();
82 }
83
84 }
This page took 0.031808 seconds and 5 git commands to generate.