author | lkorinth |
Wed, 21 Mar 2018 10:35:13 +0100 | |
changeset 49471 | bed9f0842578 |
parent 47216 | 71c04702a3d5 |
child 49620 | f6e5a1e3a862 |
permissions | -rw-r--r-- |
18025 | 1 |
<?xml version="1.0" encoding="utf-8"?> |
2 |
<!-- |
|
49471
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
3 |
Copyright (c) 2012, 2018, Oracle and/or its affiliates. All rights reserved. |
18025 | 4 |
DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
5 |
||
6 |
This code is free software; you can redistribute it and/or modify it |
|
7 |
under the terms of the GNU General Public License version 2 only, as |
|
8 |
published by the Free Software Foundation. |
|
9 |
||
10 |
This code is distributed in the hope that it will be useful, but WITHOUT |
|
11 |
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
12 |
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
13 |
version 2 for more details (a copy is included in the LICENSE file that |
|
14 |
accompanied this code). |
|
15 |
||
16 |
You should have received a copy of the GNU General Public License version |
|
17 |
2 along with this work; if not, write to the Free Software Foundation, |
|
18 |
Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
19 |
||
20 |
Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
|
21 |
or visit www.oracle.com if you need additional information or have any |
|
22 |
questions. |
|
23 |
--> |
|
24 |
||
25 |
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0"> |
|
21066
c0702325ba9d
8026703: Wrongly placed <xsl:import> element in Event-Based JVM Tracing .xsl files
simonis
parents:
18025
diff
changeset
|
26 |
<xsl:import href="xsl_util.xsl"/> |
18025 | 27 |
<xsl:output method="text" indent="no" omit-xml-declaration="yes"/> |
28 |
||
29 |
<xsl:template match="/"> |
|
30 |
<xsl:call-template name="file-header"/> |
|
31 |
||
32 |
#ifndef TRACEFILES_TRACEEVENTCLASSES_HPP |
|
33 |
#define TRACEFILES_TRACEEVENTCLASSES_HPP |
|
34 |
||
35 |
// On purpose outside the INCLUDE_TRACE |
|
36 |
// Some parts of traceEvent.hpp are used outside of |
|
37 |
// INCLUDE_TRACE |
|
38 |
||
39 |
#include "tracefiles/traceTypes.hpp" |
|
46994
7663ce98384b
8179040: Avoid Ticks::now calls when EventClassLoad is not enabled
redestad
parents:
42643
diff
changeset
|
40 |
#include "utilities/macros.hpp" |
7663ce98384b
8179040: Avoid Ticks::now calls when EventClassLoad is not enabled
redestad
parents:
42643
diff
changeset
|
41 |
|
7663ce98384b
8179040: Avoid Ticks::now calls when EventClassLoad is not enabled
redestad
parents:
42643
diff
changeset
|
42 |
#if INCLUDE_TRACE |
18025 | 43 |
#include "trace/traceEvent.hpp" |
44 |
#include "trace/traceStream.hpp" |
|
45 |
#include "utilities/ostream.hpp" |
|
46 |
||
47 |
<xsl:apply-templates select="trace/events/struct" mode="trace"/> |
|
48 |
<xsl:apply-templates select="trace/events/event" mode="trace"/> |
|
49 |
||
27673
df559a888b9f
8065361: Fixup headers and definitions for INCLUDE_TRACE
mgronlun
parents:
27634
diff
changeset
|
50 |
#else // !INCLUDE_TRACE |
18025 | 51 |
|
52 |
class TraceEvent { |
|
53 |
public: |
|
54 |
TraceEvent() {} |
|
36384 | 55 |
void set_starttime(const Ticks& ignore) {} |
56 |
void set_endtime(const Ticks& ignore) {} |
|
18025 | 57 |
bool should_commit() const { return false; } |
27634
e6b8ad4d87ac
8064348: Add TraceEvent::is_enabled() for embedded/minimal builds
mlarsson
parents:
21767
diff
changeset
|
58 |
static bool is_enabled() { return false; } |
35934
76dbe86f3d82
8138562: Event based tracing should cover monitor inflation
dsimms
parents:
35473
diff
changeset
|
59 |
void commit() {} |
18025 | 60 |
}; |
61 |
||
62 |
<xsl:apply-templates select="trace/events/struct" mode="empty"/> |
|
63 |
<xsl:apply-templates select="trace/events/event" mode="empty"/> |
|
64 |
||
27673
df559a888b9f
8065361: Fixup headers and definitions for INCLUDE_TRACE
mgronlun
parents:
27634
diff
changeset
|
65 |
#endif // INCLUDE_TRACE |
df559a888b9f
8065361: Fixup headers and definitions for INCLUDE_TRACE
mgronlun
parents:
27634
diff
changeset
|
66 |
#endif // TRACEFILES_TRACEEVENTCLASSES_HPP |
18025 | 67 |
</xsl:template> |
68 |
||
69 |
<xsl:template match="struct" mode="trace"> |
|
70 |
struct TraceStruct<xsl:value-of select="@id"/> |
|
71 |
{ |
|
72 |
private: |
|
73 |
<xsl:apply-templates select="value" mode="write-fields"/> |
|
74 |
public: |
|
75 |
<xsl:apply-templates select="value" mode="write-setters"/> |
|
76 |
||
77 |
void writeStruct(TraceStream& ts) { |
|
78 |
<xsl:apply-templates select="value" mode="write-data"/> |
|
79 |
} |
|
80 |
}; |
|
81 |
||
82 |
</xsl:template> |
|
83 |
||
84 |
<xsl:template match="struct" mode="empty"> |
|
85 |
struct TraceStruct<xsl:value-of select="@id"/> |
|
86 |
{ |
|
87 |
public: |
|
88 |
<xsl:apply-templates select="value" mode="write-empty-setters"/> |
|
89 |
}; |
|
90 |
</xsl:template> |
|
91 |
||
92 |
||
93 |
<xsl:template match="event" mode="empty"> |
|
94 |
<xsl:value-of select="concat('class Event', @id, ' : public TraceEvent')"/> |
|
95 |
{ |
|
96 |
public: |
|
97 |
<xsl:value-of select="concat(' Event', @id, '(bool ignore=true) {}')"/> |
|
98 |
<xsl:text> |
|
99 |
</xsl:text> |
|
100 |
||
101 |
<xsl:apply-templates select="value|structvalue|transition_value|relation" mode="write-empty-setters"/> |
|
102 |
}; |
|
103 |
||
104 |
</xsl:template> |
|
105 |
||
106 |
||
107 |
<xsl:template match="event" mode="trace"> |
|
108 |
<xsl:value-of select="concat('class Event', @id, ' : public TraceEvent<Event', @id, '>')"/> |
|
109 |
{ |
|
110 |
public: |
|
111 |
static const bool hasThread = <xsl:value-of select="@has_thread"/>; |
|
112 |
static const bool hasStackTrace = <xsl:value-of select="@has_stacktrace"/>; |
|
113 |
static const bool isInstant = <xsl:value-of select="@is_instant"/>; |
|
114 |
static const bool isRequestable = <xsl:value-of select="@is_requestable"/>; |
|
115 |
static const TraceEventId eventId = <xsl:value-of select="concat('Trace', @id, 'Event')"/>; |
|
116 |
||
117 |
private: |
|
118 |
<xsl:apply-templates select="value|structvalue|transition_value|relation" mode="write-fields"/> |
|
119 |
||
120 |
void writeEventContent(void) { |
|
42643 | 121 |
TraceStream ts; |
18025 | 122 |
ts.print("<xsl:value-of select="@label"/>: ["); |
123 |
<xsl:apply-templates select="value|structvalue" mode="write-data"/> |
|
124 |
ts.print("]\n"); |
|
125 |
} |
|
126 |
||
127 |
public: |
|
128 |
<xsl:apply-templates select="value|structvalue|transition_value|relation" mode="write-setters"/> |
|
129 |
||
130 |
bool should_write(void) { |
|
131 |
return true; |
|
132 |
} |
|
133 |
<xsl:text> |
|
134 |
||
135 |
</xsl:text> |
|
136 |
<xsl:value-of select="concat(' Event', @id, '(EventStartTime timing=TIMED) : TraceEvent<Event', @id, '>(timing) {}', $newline)"/> |
|
137 |
void writeEvent(void) { |
|
138 |
if (UseLockedTracing) { |
|
139 |
ttyLocker lock; |
|
140 |
writeEventContent(); |
|
141 |
} else { |
|
142 |
writeEventContent(); |
|
143 |
} |
|
144 |
} |
|
49471
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
145 |
|
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
146 |
using TraceEvent::commit; // else commit() is hidden by overloaded versions in this class |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
147 |
<xsl:variable name="instant" select="@is_instant"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
148 |
<!-- non static method (only for non instant events)--> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
149 |
<xsl:if test="$instant='false'"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
150 |
<xsl:value-of select="concat(' Event', @id)"/>( |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
151 |
<xsl:for-each select="value|structvalue|transition_value|relation"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
152 |
<xsl:apply-templates select="." mode="cpp-type"/><xsl:value-of select="concat(' ', @field)"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
153 |
<xsl:if test="position() != last()">, |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
154 |
</xsl:if></xsl:for-each>) : TraceEvent<<xsl:value-of select="concat('Event', @id)"/>>(TIMED) { |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
155 |
if (should_commit()) {<xsl:for-each select="value|structvalue|transition_value|relation"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
156 |
set_<xsl:value-of select="@field"/>(<xsl:value-of select="@field"/>);</xsl:for-each> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
157 |
} |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
158 |
} |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
159 |
|
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
160 |
void commit(<xsl:for-each select="value|structvalue|transition_value|relation"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
161 |
<xsl:apply-templates select="." mode="cpp-type"/><xsl:value-of select="concat(' ', @field)"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
162 |
<xsl:if test="position() != last()">, |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
163 |
</xsl:if></xsl:for-each>) { |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
164 |
if (should_commit()) { |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
165 |
<xsl:for-each select="value|structvalue|transition_value|relation">set_<xsl:value-of select="@field"/>(<xsl:value-of select="@field"/>); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
166 |
</xsl:for-each>commit(); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
167 |
} |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
168 |
}</xsl:if> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
169 |
<!-- static method (for all events) --> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
170 |
static void commit(<xsl:if test="$instant='false'">const Ticks& startTicks, |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
171 |
const Ticks& endTicks<xsl:choose><xsl:when test="value|structvalue|transition_value|relation">, |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
172 |
</xsl:when></xsl:choose></xsl:if> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
173 |
<xsl:for-each select="value|structvalue|transition_value|relation"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
174 |
<xsl:apply-templates select="." mode="cpp-type"/><xsl:value-of select="concat(' ', @field)"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
175 |
<xsl:if test="position() != last()">, |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
176 |
</xsl:if></xsl:for-each>) { |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
177 |
<xsl:value-of select="concat('Event', @id)"/> me(UNTIMED); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
178 |
|
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
179 |
if (me.should_commit()) { |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
180 |
<xsl:if test="$instant='false'">me.set_starttime(startTicks); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
181 |
me.set_endtime(endTicks); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
182 |
</xsl:if> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
183 |
<xsl:for-each select="value|structvalue|transition_value|relation">me.set_<xsl:value-of select="@field"/>(<xsl:value-of select="@field"/>); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
184 |
</xsl:for-each>me.commit(); |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
185 |
} |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
186 |
} |
18025 | 187 |
}; |
188 |
||
189 |
</xsl:template> |
|
190 |
||
191 |
<xsl:template match="value|transition_value|relation" mode="write-empty-setters"> |
|
192 |
<xsl:param name="cls"/> |
|
193 |
<xsl:variable name="type" select="@type"/> |
|
194 |
<xsl:variable name="wt" select="//primary_type[@symbol=$type]/@type"/> |
|
195 |
<xsl:value-of select="concat(' void set_', @field, '(', $wt, ' value) { }')"/> |
|
196 |
<xsl:if test="position() != last()"> |
|
197 |
<xsl:text> |
|
198 |
</xsl:text> |
|
199 |
</xsl:if> |
|
200 |
</xsl:template> |
|
201 |
||
202 |
<xsl:template match="structvalue" mode="write-empty-setters"> |
|
203 |
<xsl:param name="cls"/> |
|
204 |
<xsl:value-of select="concat(' void set_', @field, '(const TraceStruct', @type, '& value) { }')"/> |
|
205 |
<xsl:if test="position() != last()"> |
|
206 |
<xsl:text> |
|
207 |
</xsl:text> |
|
208 |
</xsl:if> |
|
209 |
</xsl:template> |
|
210 |
||
211 |
<xsl:template match="value[@type='TICKS']" mode="write-setters"> |
|
212 |
#if INCLUDE_TRACE |
|
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
213 |
<xsl:value-of select="concat(' void set_', @field, '(const Ticks& time) { _', @field, ' = time; }')"/> |
18025 | 214 |
#else |
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
215 |
<xsl:value-of select="concat(' void set_', @field, '(const Ticks& ignore) {}')"/> |
18025 | 216 |
#endif |
217 |
</xsl:template> |
|
218 |
||
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
219 |
<xsl:template match="value[@type='TICKSPAN']" mode="write-setters"> |
18025 | 220 |
#if INCLUDE_TRACE |
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
221 |
<xsl:value-of select="concat(' void set_', @field, '(const Tickspan& time) { _', @field, ' = time; }')"/> |
18025 | 222 |
#else |
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
223 |
<xsl:value-of select="concat(' void set_', @field, '(const Tickspan& ignore) {}')"/> |
18025 | 224 |
#endif |
225 |
</xsl:template> |
|
226 |
||
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
227 |
|
18025 | 228 |
<xsl:template match="value" mode="write-fields"> |
229 |
<xsl:variable name="type" select="@type"/> |
|
230 |
<xsl:variable name="wt" select="//primary_type[@symbol=$type]/@type"/> |
|
231 |
<xsl:value-of select="concat(' ', $wt, ' _', @field, ';')"/> |
|
232 |
<xsl:if test="position() != last()"> |
|
233 |
<xsl:text> |
|
234 |
</xsl:text> |
|
235 |
</xsl:if> |
|
236 |
</xsl:template> |
|
237 |
||
238 |
<xsl:template match="structvalue" mode="write-fields"> |
|
239 |
<xsl:value-of select="concat(' TraceStruct', @type, ' _', @field, ';')"/> |
|
240 |
<xsl:text> |
|
241 |
</xsl:text> |
|
242 |
</xsl:template> |
|
243 |
||
244 |
<xsl:template match="value|transition_value|relation" mode="write-setters"> |
|
245 |
<xsl:param name="cls"/> |
|
246 |
<xsl:variable name="type" select="@type"/> |
|
247 |
<xsl:variable name="wt" select="//primary_type[@symbol=$type]/@type"/> |
|
248 |
<xsl:value-of select="concat(' void set_', @field, '(', $wt, ' value) { this->_', @field, ' = value; }')"/> |
|
249 |
<xsl:if test="position() != last()"> |
|
250 |
<xsl:text> |
|
251 |
</xsl:text> |
|
252 |
</xsl:if> |
|
253 |
</xsl:template> |
|
254 |
||
255 |
<xsl:template match="structvalue" mode="write-setters"> |
|
256 |
<xsl:param name="cls"/> |
|
257 |
<xsl:value-of select="concat(' void set_', @field, '(const TraceStruct', @type, '& value) { this->_', @field, ' = value; }')"/> |
|
258 |
<xsl:if test="position() != last()"> |
|
259 |
<xsl:text> |
|
260 |
</xsl:text> |
|
261 |
</xsl:if> |
|
262 |
</xsl:template> |
|
263 |
||
264 |
<xsl:template match="value" mode="write-data"> |
|
265 |
<xsl:variable name="type" select="@type"/> |
|
266 |
<xsl:variable name="wt" select="//primary_type[@symbol=$type]/@writetype"/> |
|
21767
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
267 |
<xsl:choose> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
268 |
<xsl:when test="@type='TICKSPAN'"> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
269 |
<xsl:value-of select="concat(' ts.print_val("', @label, '", _', @field, '.value());')"/> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
270 |
</xsl:when> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
271 |
<xsl:when test="@type='TICKS'"> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
272 |
<xsl:value-of select="concat(' ts.print_val("', @label, '", _', @field, '.value());')"/> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
273 |
</xsl:when> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
274 |
<xsl:otherwise> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
275 |
<xsl:value-of select="concat(' ts.print_val("', @label, '", _', @field, ');')"/> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
276 |
</xsl:otherwise> |
41eaa9a17059
8028128: Add a type safe alternative for working with counter based data
mgronlun
parents:
21066
diff
changeset
|
277 |
</xsl:choose> |
18025 | 278 |
<xsl:if test="position() != last()"> |
279 |
<xsl:text> |
|
280 |
ts.print(", "); |
|
281 |
</xsl:text> |
|
282 |
</xsl:if> |
|
283 |
</xsl:template> |
|
284 |
||
285 |
<xsl:template match="structvalue" mode="write-data"> |
|
286 |
<xsl:value-of select="concat(' _', @field, '.writeStruct(ts);')"/> |
|
287 |
<xsl:if test="position() != last()"> |
|
288 |
<xsl:text> |
|
289 |
ts.print(", "); |
|
290 |
</xsl:text> |
|
291 |
</xsl:if> |
|
292 |
</xsl:template> |
|
293 |
||
49471
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
294 |
|
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
295 |
<xsl:template match="value|transition_value|relation" mode="cpp-type"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
296 |
<xsl:variable name="type" select="@type"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
297 |
<xsl:value-of select="//primary_type[@symbol=$type]/@type"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
298 |
</xsl:template> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
299 |
<xsl:template match="structvalue" mode="cpp-type"> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
300 |
<xsl:value-of select="concat('const TraceStruct', @type, '&')"/> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
301 |
</xsl:template> |
bed9f0842578
8196337: Add commit methods that take all event properties as argument
lkorinth
parents:
47216
diff
changeset
|
302 |
|
18025 | 303 |
</xsl:stylesheet> |