lttng.control: Replacing isKernel with an enum for the domain type
[deliverable/tracecompass.git] / lttng / org.eclipse.tracecompass.lttng2.control.ui.tests / stubs / org / eclipse / tracecompass / internal / lttng2 / control / stubs / dialogs / GetEventInfoDialogStub.java
CommitLineData
a26d90be 1/**********************************************************************
ed902a2b 2 * Copyright (c) 2012, 2014 Ericsson
d4514365 3 *
a26d90be
BH
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
d4514365
BH
8 *
9 * Contributors:
a26d90be
BH
10 * Bernd Hufmann - Initial API and implementation
11 **********************************************************************/
9bc60be7 12package org.eclipse.tracecompass.internal.lttng2.control.stubs.dialogs;
a26d90be 13
1f2f091b
BH
14import java.util.Arrays;
15
1bc37054 16import org.eclipse.tracecompass.internal.lttng2.control.core.model.TraceDomainType;
9bc60be7
AM
17import org.eclipse.tracecompass.internal.lttng2.control.ui.views.dialogs.IGetEventInfoDialog;
18import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceChannelComponent;
19import org.eclipse.tracecompass.internal.lttng2.control.ui.views.model.impl.TraceSessionComponent;
a26d90be
BH
20
21/**
d4514365 22 * Get event information dialog stub implementation.
a26d90be
BH
23 */
24public class GetEventInfoDialogStub implements IGetEventInfoDialog {
25
26 private TraceSessionComponent[] fSessions;
d4514365
BH
27 private String fFilterExpression;
28
a26d90be
BH
29 @Override
30 public TraceSessionComponent getSession() {
31 return fSessions[0];
32 }
33
34 @Override
35 public TraceChannelComponent getChannel() {
36 return null;
37 }
38
39 @Override
1bc37054 40 public void setDomain(TraceDomainType domain) {
a26d90be
BH
41 }
42
43 @Override
44 public void setSessions(TraceSessionComponent[] sessions) {
1f2f091b
BH
45 if (sessions != null) {
46 fSessions = Arrays.copyOf(sessions, sessions.length);
47 return;
48 }
49 fSessions = null;
a26d90be
BH
50 }
51
d4514365
BH
52 @Override
53 public String getFilterExpression() {
54 return fFilterExpression;
55 }
56
a26d90be
BH
57 @Override
58 public int open() {
59 return 0;
60 }
d4514365
BH
61
62 /**
63 * @param filter the filter to set
64 */
65 public void setFilterExpression(String filter) {
66 fFilterExpression = filter;
67 }
a26d90be
BH
68}
69
This page took 0.076381 seconds and 5 git commands to generate.