timing.ui: move logic of segment stats logic to abstract class
[deliverable/tracecompass.git] / analysis / org.eclipse.tracecompass.analysis.os.linux.ui / src / org / eclipse / tracecompass / internal / analysis / os / linux / ui / views / latency / statistics / SystemCallLatencyStatisticsViewer.java
1 /*******************************************************************************
2 * Copyright (c) 2015 Ericsson
3 *
4 * All rights reserved. This program and the accompanying materials are made
5 * 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 * Bernd Hufmann - Initial API and implementation
11 *******************************************************************************/
12 package org.eclipse.tracecompass.internal.analysis.os.linux.ui.views.latency.statistics;
13
14 import static org.eclipse.tracecompass.common.core.NonNullUtils.checkNotNull;
15
16 import org.eclipse.jdt.annotation.NonNull;
17 import org.eclipse.jdt.annotation.Nullable;
18 import org.eclipse.swt.widgets.Composite;
19 import org.eclipse.tracecompass.analysis.timing.ui.views.segmentstore.statistics.AbstractSegmentStoreStatisticsViewer;
20 import org.eclipse.tracecompass.internal.analysis.os.linux.core.latency.statistics.SystemCallLatencyStatisticsAnalysisModule;
21 import org.eclipse.tracecompass.tmf.core.analysis.TmfAbstractAnalysisModule;
22
23 /**
24 * A tree viewer implementation for displaying latency statistics
25 *
26 * @author Bernd Hufmann
27 *
28 */
29 public class SystemCallLatencyStatisticsViewer extends AbstractSegmentStoreStatisticsViewer {
30
31 private static final String SYSCALL_LEVEL = checkNotNull(Messages.LatencyStatistics_SyscallLevelName);
32
33 /**
34 * Constructor
35 *
36 * @param parent
37 * the parent composite
38 */
39 public SystemCallLatencyStatisticsViewer(Composite parent) {
40 super(parent);
41 }
42
43 /**
44 * Gets the statistics analysis module
45 *
46 * @return the statistics analysis module
47 */
48 @Override
49 protected @Nullable TmfAbstractAnalysisModule createStatisticsAnalysiModule() {
50 SystemCallLatencyStatisticsAnalysisModule module = new SystemCallLatencyStatisticsAnalysisModule();
51 return module;
52 }
53
54 @Override
55 protected @NonNull final String getTotalLabel() {
56 return checkNotNull(Messages.LatencyStatistics_TotalLabel);
57 }
58
59 @Override
60 protected @NonNull final String getTypeLabel() {
61 return SYSCALL_LEVEL;
62 }
63
64
65
66 }
This page took 0.03344 seconds and 6 git commands to generate.