Commit | Line | Data |
---|---|---|
3335f36e AM |
1 | /******************************************************************************* |
2 | * Copyright (c) 2016 EfficiOS Inc., Alexandre Montplaisir | |
3 | * | |
4 | * All rights reserved. This program and the accompanying materials | |
5 | * are made available under the terms of the Eclipse Public License v1.0 | |
6 | * which accompanies this distribution, and is available at | |
7 | * http://www.eclipse.org/legal/epl-v10.html | |
8 | *******************************************************************************/ | |
9 | ||
10 | package org.eclipse.tracecompass.lttng2.ust.core.analysis.debuginfo; | |
11 | ||
12 | import org.eclipse.jdt.annotation.Nullable; | |
13 | import org.eclipse.tracecompass.tmf.core.event.lookup.TmfCallsite; | |
14 | ||
15 | /** | |
16 | * Extension of {@link TmfCallsite} specifically for the debug-info analysis, | |
17 | * which will not print the function name in the event table. This name will be | |
18 | * available by a separate aspect. | |
19 | * | |
20 | * @author Alexandre Montplaisir | |
21 | * @since 2.0 | |
0c65e461 | 22 | * @deprecated No need for this anymore, use {@link TmfCallsite} directly. |
3335f36e | 23 | */ |
0c65e461 | 24 | @Deprecated |
3335f36e AM |
25 | public class SourceCallsite extends TmfCallsite { |
26 | ||
27 | /** | |
28 | * Constructor | |
29 | * | |
30 | * @param fileName | |
31 | * File name | |
32 | * @param functionName | |
33 | * Function name | |
34 | * @param lineNumber | |
35 | * Line number | |
36 | */ | |
37 | public SourceCallsite(String fileName, @Nullable String functionName, long lineNumber) { | |
0c65e461 | 38 | super(fileName, lineNumber); |
3335f36e AM |
39 | } |
40 | ||
41 | @Override | |
42 | public String toString() { | |
43 | StringBuilder builder = new StringBuilder(); | |
44 | builder.append(getFileName()).append(':'); | |
45 | builder.append(Long.toString(getLineNumber())); | |
46 | return builder.toString(); | |
47 | } | |
48 | ||
49 | } |