1 /*******************************************************************************
2 * Copyright (c) 2013, 2014 Ericsson
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
10 * Patrick Tasse - Initial API and implementation
11 *******************************************************************************/
13 package org
.eclipse
.tracecompass
.tmf
.ui
.views
.callstack
;
15 import org
.eclipse
.jdt
.annotation
.NonNull
;
16 import org
.eclipse
.tracecompass
.statesystem
.core
.ITmfStateSystem
;
17 import org
.eclipse
.tracecompass
.tmf
.core
.trace
.ITmfTrace
;
18 import org
.eclipse
.tracecompass
.tmf
.ui
.widgets
.timegraph
.model
.TimeGraphEntry
;
21 * An entry, or row, in the Call Stack view
23 * @author Patrick Tasse
25 public class CallStackEntry
extends TimeGraphEntry
{
27 private final int fQuark
;
28 private final int fStackLevel
;
29 private final ITmfTrace fTrace
;
30 private String fFunctionName
;
31 private long fFunctionEntryTime
;
32 private long fFunctionExitTime
;
33 private @NonNull ITmfStateSystem fSS
;
36 * Standard constructor
39 * The call stack quark
43 * The trace that this view is talking about
44 * @deprecated Use {@link #CallStackEntry(String, int, int, ITmfTrace, ITmfStateSystem)}
47 public CallStackEntry(int quark
, int stackLevel
, ITmfTrace trace
) {
49 throw new UnsupportedOperationException();
53 * Standard constructor
56 * The parent thread name
58 * The call stack quark
62 * The trace that this view is talking about
64 * The call stack state system
66 public CallStackEntry(String name
, int quark
, int stackLevel
, ITmfTrace trace
, @NonNull ITmfStateSystem ss
) {
69 fStackLevel
= stackLevel
;
71 fFunctionName
= ""; //$NON-NLS-1$
76 * Get the function name of the call stack entry
77 * @return the function name
79 public String
getFunctionName() {
84 * Set the function name of the call stack entry
85 * @param functionName the function name
87 public void setFunctionName(String functionName
) {
88 fFunctionName
= functionName
;
92 * Set the start time of the call stack entry
93 * @param startTime the start time
94 * @deprecated Use {@link #setFunctionEntryTime(long)}
97 public void setStartTime(long startTime
) {
98 throw new UnsupportedOperationException();
102 * Set the end time of the call stack entry
103 * @param endTime the end time
104 * @deprecated Use {@link #setFunctionExitTime(long)}
107 public void setEndTime(long endTime
) {
108 throw new UnsupportedOperationException();
112 * Set the selected function entry time
115 * the function entry time
117 public void setFunctionEntryTime(long entryTime
) {
118 fFunctionEntryTime
= entryTime
;
122 * Get the selected function entry time
124 * @return the function entry time
126 public long getFunctionEntryTime() {
127 return fFunctionEntryTime
;
131 * Set the selected function exit time
134 * the function exit time
136 public void setFunctionExitTime(long exitTime
) {
137 fFunctionExitTime
= exitTime
;
141 * Get the selected function exit time
143 * @return the function exit time
145 public long getFunctionExitTime() {
146 return fFunctionExitTime
;
150 * Retrieve the attribute quark that's represented by this entry.
152 * @return The integer quark
154 public int getQuark() {
159 * Retrieve the stack level associated with this entry.
161 * @return The stack level or 0
163 public int getStackLevel() {
168 * Retrieve the trace that is associated to this view.
172 public ITmfTrace
getTrace() {
177 * Retrieve the call stack state system associated with this entry.
179 * @return The call stack state system
181 public @NonNull ITmfStateSystem
getStateSystem() {
This page took 0.034916 seconds and 5 git commands to generate.