Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
Jastadd2
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
JastAdd
Jastadd2
Commits
11a3cb2e
Commit
11a3cb2e
authored
4 years ago
by
Emma Söderberg
Browse files
Options
Downloads
Patches
Plain Diff
Add start of adding aspect info to traces
parent
7bc880fb
No related branches found
No related tags found
No related merge requests found
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/template/ast/State.tt
+1
-1
1 addition, 1 deletion
src/template/ast/State.tt
src/template/trace/TraceHooks.tt
+51
-51
51 additions, 51 deletions
src/template/trace/TraceHooks.tt
src/template/trace/Tracer.tt
+61
-57
61 additions, 57 deletions
src/template/trace/Tracer.tt
with
113 additions
and
109 deletions
src/template/ast/State.tt
+
1
−
1
View file @
11a3cb2e
...
@@ -441,7 +441,7 @@ $if(TracingEnabled)
...
@@ -441,7 +441,7 @@ $if(TracingEnabled)
public static ReceiverFactory receiverFactory = new ReceiverFactory() {
public static ReceiverFactory receiverFactory = new ReceiverFactory() {
public Trace.Receiver build() {
public Trace.Receiver build() {
return new Trace.Receiver() {
return new Trace.Receiver() {
public void accept($StateClass.Trace.Event event, $ASTNode node, String attribute,
public void accept($StateClass.Trace.Event event,
String aspect,
$ASTNode node, String attribute,
Object params, Object value) {
Object params, Object value) {
}
}
};
};
...
...
This diff is collapsed.
Click to expand it.
src/template/trace/TraceHooks.tt
+
51
−
51
View file @
11a3cb2e
...
@@ -37,7 +37,7 @@ AttrDecl.traceComputeBegin [[
...
@@ -37,7 +37,7 @@ AttrDecl.traceComputeBegin [[
$if (TraceCompute)
$if (TraceCompute)
$if(#isParameterized)
$if(#isParameterized)
$if(#isCircular)
$if(#isCircular)
state().trace().computeBegin(this, "#hostClassName.#signatureJavaStyle", _parameters, "");
state().trace().computeBegin(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, "");
$else
$else
$if(!#isMemoized)
$if(!#isMemoized)
$if(!VisitCheckEnabled)
$if(!VisitCheckEnabled)
...
@@ -48,10 +48,10 @@ Object _parameters = java.util.Arrays.asList(#parameters);
...
@@ -48,10 +48,10 @@ Object _parameters = java.util.Arrays.asList(#parameters);
$endif
$endif
$endif
$endif
$endif
$endif
state().trace().computeBegin(this, "#hostClassName.#signatureJavaStyle", _parameters, "");
state().trace().computeBegin(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, "");
$endif
$endif
$else
$else
state().trace().computeBegin(this, "#hostClassName.#signatureJavaStyle", "", "");
state().trace().computeBegin(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", "");
$endif
$endif
$endif
$endif
]]
]]
...
@@ -60,12 +60,12 @@ AttrDecl.traceComputeEnd [[
...
@@ -60,12 +60,12 @@ AttrDecl.traceComputeEnd [[
$if (TraceCompute)
$if (TraceCompute)
$if(#isParameterized)
$if(#isParameterized)
$if(#isCircular)
$if(#isCircular)
state().trace().computeEnd(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().computeEnd(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().computeEnd(this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_value);
state().trace().computeEnd(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_value);
$endif
$endif
$else
$else
state().trace().computeEnd(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().computeEnd(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
]]
]]
...
@@ -73,9 +73,9 @@ $endif
...
@@ -73,9 +73,9 @@ $endif
AttrDecl.traceComputeEndInline [[
AttrDecl.traceComputeEndInline [[
$if (TraceCompute)
$if (TraceCompute)
$if(#isParameterized)
$if(#isParameterized)
state().trace().computeEnd(this, "#hostClassName.#signatureJavaStyle", _parameters, "");
state().trace().computeEnd(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, "");
$else
$else
state().trace().computeEnd(this, "#hostClassName.#signatureJavaStyle", "", "");
state().trace().computeEnd(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", "");
$endif
$endif
$endif
$endif
]]
]]
...
@@ -85,12 +85,12 @@ $if (TraceCache)
...
@@ -85,12 +85,12 @@ $if (TraceCache)
$if(#isMemoized)
$if(#isMemoized)
$if(#isParameterized)
$if(#isParameterized)
$if(#isCircular)
$if(#isCircular)
state().trace().cacheRead(this, "#hostClassName.#signatureJavaStyle", _parameters, _cache);
state().trace().cacheRead(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _cache);
$else
$else
state().trace().cacheRead(this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_values.get(_parameters));
state().trace().cacheRead(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_values.get(_parameters));
$endif
$endif
$else
$else
state().trace().cacheRead(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().cacheRead(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -101,12 +101,12 @@ $if (TraceCache)
...
@@ -101,12 +101,12 @@ $if (TraceCache)
$if(#isMemoized)
$if(#isMemoized)
$if(#isParameterized)
$if(#isParameterized)
$if(#isCircular)
$if(#isCircular)
state().trace().cacheWrite(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().cacheWrite(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().cacheWrite(this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_value);
state().trace().cacheWrite(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_value);
$endif
$endif
$else
$else
state().trace().cacheWrite(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().cacheWrite(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -117,12 +117,12 @@ $if (TraceCache)
...
@@ -117,12 +117,12 @@ $if (TraceCache)
$if(#isMemoized)
$if(#isMemoized)
$if(#isParameterized)
$if(#isParameterized)
$if(#isCircular)
$if(#isCircular)
state().trace().cacheAbort(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().cacheAbort(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().cacheAbort(this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_value);
state().trace().cacheAbort(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, #(signature)_value);
$endif
$endif
$else
$else
state().trace().cacheAbort(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().cacheAbort(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -132,15 +132,15 @@ AttrDecl.traceCircularEnterCase1 [[
...
@@ -132,15 +132,15 @@ AttrDecl.traceCircularEnterCase1 [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().enterCircularNTACase1(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().enterCircularNTACase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().enterCircularNTACase1(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().enterCircularNTACase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().enterCircularCase1(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().enterCircularCase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().enterCircularCase1(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().enterCircularCase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -150,18 +150,18 @@ AttrDecl.traceCircularCase1Change [[
...
@@ -150,18 +150,18 @@ AttrDecl.traceCircularCase1Change [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().circularNTACase1Change(this, "#hostClassName.#signatureJavaStyle", _parameters,
state().trace().circularNTACase1Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters,
_value.value + "->" + new_#(signature)_value);
_value.value + "->" + new_#(signature)_value);
$else
$else
state().trace().circularNTACase1Change(this, "#hostClassName.#signatureJavaStyle", "",
state().trace().circularNTACase1Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "",
#(signature)_value + "->" + new_#(signature)_value);
#(signature)_value + "->" + new_#(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().circularCase1Change(this, "#hostClassName.#signatureJavaStyle", _parameters,
state().trace().circularCase1Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters,
_value.value + "->" + new_#(signature)_value);
_value.value + "->" + new_#(signature)_value);
$else
$else
state().trace().circularCase1Change(this, "#hostClassName.#signatureJavaStyle", "",
state().trace().circularCase1Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "",
#(signature)_value + "->" + new_#(signature)_value);
#(signature)_value + "->" + new_#(signature)_value);
$endif
$endif
$endif
$endif
...
@@ -172,15 +172,15 @@ AttrDecl.traceCircularExitCase1 [[
...
@@ -172,15 +172,15 @@ AttrDecl.traceCircularExitCase1 [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().exitCircularNTACase1(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().exitCircularNTACase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().exitCircularNTACase1(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().exitCircularNTACase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().exitCircularCase1(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().exitCircularCase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().exitCircularCase1(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().exitCircularCase1(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -190,15 +190,15 @@ AttrDecl.traceCircularEnterCase2 [[
...
@@ -190,15 +190,15 @@ AttrDecl.traceCircularEnterCase2 [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().enterCircularNTACase2(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().enterCircularNTACase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().enterCircularNTACase2(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().enterCircularNTACase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().enterCircularCase2(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().enterCircularCase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().enterCircularCase2(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().enterCircularCase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -208,18 +208,18 @@ AttrDecl.traceCircularCase2Change [[
...
@@ -208,18 +208,18 @@ AttrDecl.traceCircularCase2Change [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().circularNTACase2Change(this, "#hostClassName.#signatureJavaStyle", _parameters,
state().trace().circularNTACase2Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters,
_value.value + "->" + new_#(signature)_value);
_value.value + "->" + new_#(signature)_value);
$else
$else
state().trace().circularNTACase2Change(this, "#hostClassName.#signatureJavaStyle", "",
state().trace().circularNTACase2Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "",
#(signature)_value + "->" + new_#(signature)_value);
#(signature)_value + "->" + new_#(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().circularCase2Change(this, "#hostClassName.#signatureJavaStyle", _parameters,
state().trace().circularCase2Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters,
_value.value + "->" + new_#(signature)_value);
_value.value + "->" + new_#(signature)_value);
$else
$else
state().trace().circularCase2Change(this, "#hostClassName.#signatureJavaStyle", "",
state().trace().circularCase2Change(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "",
#(signature)_value + "->" + new_#(signature)_value);
#(signature)_value + "->" + new_#(signature)_value);
$endif
$endif
$endif
$endif
...
@@ -230,15 +230,15 @@ AttrDecl.traceCircularExitCase2 [[
...
@@ -230,15 +230,15 @@ AttrDecl.traceCircularExitCase2 [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().exitCircularNTACase2(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().exitCircularNTACase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().exitCircularNTACase2(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().exitCircularNTACase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().exitCircularCase2(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().exitCircularCase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().exitCircularCase2(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().exitCircularCase2(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -248,15 +248,15 @@ AttrDecl.traceCircularExitCase3 [[
...
@@ -248,15 +248,15 @@ AttrDecl.traceCircularExitCase3 [[
$if (TraceCircular)
$if (TraceCircular)
$if(#getNTA)
$if(#getNTA)
$if(#isParameterized)
$if(#isParameterized)
state().trace().exitCircularNTACase3(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().exitCircularNTACase3(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().exitCircularNTACase3(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().exitCircularNTACase3(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$else
$else
$if(#isParameterized)
$if(#isParameterized)
state().trace().exitCircularCase3(this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
state().trace().exitCircularCase3(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", _parameters, _value.value);
$else
$else
state().trace().exitCircularCase3(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().exitCircularCase3(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
$endif
$endif
...
@@ -316,31 +316,31 @@ $endif
...
@@ -316,31 +316,31 @@ $endif
AttrDecl.traceFlushAttr [[
AttrDecl.traceFlushAttr [[
$if (TraceFlush)
$if (TraceFlush)
$if(#isParameterized)
$if(#isParameterized)
state().trace().flushAttr(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_values);
state().trace().flushAttr(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_values);
$else
$else
state().trace().flushAttr(this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
state().trace().flushAttr(
"#getAspectName",
this, "#hostClassName.#signatureJavaStyle", "", #(signature)_value);
$endif
$endif
$endif
$endif
]]
]]
CollEq.traceContributionCheckBegin [[
CollEq.traceContributionCheckBegin [[
$if (TraceColl)
$if (TraceColl)
state().trace().contributionCheckBegin(this, "#collectionId", "#escapeConditionForTemplate");
state().trace().contributionCheckBegin(
"#getAspectName",
this, "#collectionId", "#escapeConditionForTemplate");
$endif
$endif
]]
]]
CollEq.traceContributionCheckEnd [[
CollEq.traceContributionCheckEnd [[
$if (TraceColl)
$if (TraceColl)
state().trace().contributionCheckEnd(this, "#collectionId", "#escapeConditionForTemplate");
state().trace().contributionCheckEnd(
"#getAspectName",
this, "#collectionId", "#escapeConditionForTemplate");
$endif
$endif
]]
]]
CollEq.traceContributionCheckMatch [[
CollEq.traceContributionCheckMatch [[
$if (TraceColl)
$if (TraceColl)
$if(#iterableValue)
$if(#iterableValue)
state().trace().contributionCheckMatch(this, "#collectionId", "#escapeConditionForTemplate", value);
state().trace().contributionCheckMatch(
"#getAspectName",
this, "#collectionId", "#escapeConditionForTemplate", value);
$else
$else
state().trace().contributionCheckMatch(this, "#collectionId", "#escapeConditionForTemplate", #getValue);
state().trace().contributionCheckMatch(
"#getAspectName",
this, "#collectionId", "#escapeConditionForTemplate", #getValue);
$endif
$endif
$endif
$endif
]]
]]
...
...
This diff is collapsed.
Click to expand it.
src/template/trace/Tracer.tt
+
61
−
57
View file @
11a3cb2e
...
@@ -90,12 +90,16 @@ public static class Trace {
...
@@ -90,12 +90,16 @@ public static class Trace {
TOKEN_READ;
TOKEN_READ;
}
}
// For traced operations inherent in all ASTs, e.g., copy, or from elements
// derived from the grammar, e.g., tokens.
public static final String ASPECT_AST = "AST";
/**
/**
* Functional interface for a trace event receiver.
* Functional interface for a trace event receiver.
* This can be implemented by applications that want to trace attribute evaluation.
* This can be implemented by applications that want to trace attribute evaluation.
*/
*/
public interface Receiver {
public interface Receiver {
void accept($StateClass.Trace.Event event, $ASTNode node, String attribute,
void accept($StateClass.Trace.Event event,
String aspect,
$ASTNode node, String attribute,
Object params, Object value);
Object params, Object value);
}
}
...
@@ -108,7 +112,7 @@ public static class Trace {
...
@@ -108,7 +112,7 @@ public static class Trace {
// The default event receiver does nothing.
// The default event receiver does nothing.
private Receiver receiver = new Receiver() {
private Receiver receiver = new Receiver() {
public void accept($StateClass.Trace.Event event, $ASTNode node, String attribute,
public void accept($StateClass.Trace.Event event,
String aspect,
$ASTNode node, String attribute,
Object params, Object value) {
Object params, Object value) {
}
}
};
};
...
@@ -129,40 +133,40 @@ public static class Trace {
...
@@ -129,40 +133,40 @@ public static class Trace {
* Trace that an attribute instance started its computation.
* Trace that an attribute instance started its computation.
* @param value The value of the attribute instance.
* @param value The value of the attribute instance.
*/
*/
public void computeBegin($ASTNode node, String attr, Object params, Object value) {
public void computeBegin(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept(Event.COMPUTE_BEGIN, node, attr, params, value);
receiver.accept(Event.COMPUTE_BEGIN,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that an attribute instance ended its computation.
* Trace that an attribute instance ended its computation.
* @param value The value of the attribute instance.
* @param value The value of the attribute instance.
*/
*/
public void computeEnd($ASTNode node, String attr, Object params, Object value) {
public void computeEnd(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.COMPUTE_END, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.COMPUTE_END,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that the cache of an attribute instances was read.
* Trace that the cache of an attribute instances was read.
* @param value The value of the attribute instance.
* @param value The value of the attribute instance.
*/
*/
public void cacheRead($ASTNode node, String attr, Object params, Object value) {
public void cacheRead(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CACHE_READ, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CACHE_READ,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that an attribute instance was cached.
* Trace that an attribute instance was cached.
* @param value The value of the attribute instance.
* @param value The value of the attribute instance.
*/
*/
public void cacheWrite($ASTNode node, String attr, Object params, Object value) {
public void cacheWrite(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CACHE_WRITE, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CACHE_WRITE,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that the caching of an attribute instance was aborted.
* Trace that the caching of an attribute instance was aborted.
* @param value The value of the attribute instance.
* @param value The value of the attribute instance.
*/
*/
public void cacheAbort($ASTNode node, String attr, Object params, Object value) {
public void cacheAbort(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CACHE_ABORT, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CACHE_ABORT,
aspect,
node, attr, params, value);
}
}
/**
/**
...
@@ -170,7 +174,7 @@ public static class Trace {
...
@@ -170,7 +174,7 @@ public static class Trace {
* @param value The value of the rewrite.
* @param value The value of the rewrite.
*/
*/
public void enterRewriteCase1($ASTNode node, String attr, Object params, Object value) {
public void enterRewriteCase1($ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.REWRITE_CASE1_START, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.REWRITE_CASE1_START,
ASPECT_AST,
node, attr, params, value);
}
}
/**
/**
...
@@ -178,7 +182,7 @@ public static class Trace {
...
@@ -178,7 +182,7 @@ public static class Trace {
* @param value The value of the rewrite before and after.
* @param value The value of the rewrite before and after.
*/
*/
public void rewriteChange($ASTNode node, String attr, Object params, Object value) {
public void rewriteChange($ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.REWRITE_CASE1_CHANGE, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.REWRITE_CASE1_CHANGE,
ASPECT_AST,
node, attr, params, value);
}
}
/**
/**
...
@@ -186,7 +190,7 @@ public static class Trace {
...
@@ -186,7 +190,7 @@ public static class Trace {
* @param value The value of the rewrite.
* @param value The value of the rewrite.
*/
*/
public void exitRewriteCase1($ASTNode node, String attr, Object params, Object value) {
public void exitRewriteCase1($ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.REWRITE_CASE1_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.REWRITE_CASE1_RETURN,
ASPECT_AST,
node, attr, params, value);
}
}
/**
/**
...
@@ -194,7 +198,7 @@ public static class Trace {
...
@@ -194,7 +198,7 @@ public static class Trace {
* @param value The value of the rewrite.
* @param value The value of the rewrite.
*/
*/
public void exitRewriteCase2($ASTNode node, String attr, Object params, Object value) {
public void exitRewriteCase2($ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.REWRITE_CASE2_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.REWRITE_CASE2_RETURN,
ASPECT_AST,
node, attr, params, value);
}
}
/**
/**
...
@@ -202,119 +206,119 @@ public static class Trace {
...
@@ -202,119 +206,119 @@ public static class Trace {
* @param value The value of the rewrite.
* @param value The value of the rewrite.
*/
*/
public void exitRewriteCase3($ASTNode node, String attr, Object params, Object value) {
public void exitRewriteCase3($ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.REWRITE_CASE3_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.REWRITE_CASE3_RETURN,
ASPECT_AST,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance entered evaluation case 1.
* Trace that a circular attribute instance entered evaluation case 1.
* @param value The value of the circular attribute instance.
* @param value The value of the circular attribute instance.
*/
*/
public void enterCircularCase1($ASTNode node, String attr, Object params, Object value) {
public void enterCircularCase1(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE1_START, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE1_START,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance in evaluation case 1 changed value.
* Trace that a circular attribute instance in evaluation case 1 changed value.
* @param value The value of the circular attribute instance, before and after.
* @param value The value of the circular attribute instance, before and after.
*/
*/
public void circularCase1Change($ASTNode node, String attr, Object params, Object value) {
public void circularCase1Change(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE1_CHANGE, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE1_CHANGE,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance returned from evaluation case 1.
* Trace that a circular attribute instance returned from evaluation case 1.
* @param value The value of the circular attribute instance.
* @param value The value of the circular attribute instance.
*/
*/
public void exitCircularCase1($ASTNode node, String attr, Object params, Object value) {
public void exitCircularCase1(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE1_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE1_RETURN,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance entered evaluation case 2.
* Trace that a circular attribute instance entered evaluation case 2.
* @param value The value of the circular attribute instance.
* @param value The value of the circular attribute instance.
*/
*/
public void enterCircularCase2($ASTNode node, String attr, Object params, Object value) {
public void enterCircularCase2(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE2_START, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE2_START,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance in evaluation case 2 changed value.
* Trace that a circular attribute instance in evaluation case 2 changed value.
* @param value The value of the circular attribute instance, before and after.
* @param value The value of the circular attribute instance, before and after.
*/
*/
public void circularCase2Change($ASTNode node, String attr, Object params, Object value) {
public void circularCase2Change(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE2_CHANGE, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE2_CHANGE,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance returned from evaluation case 2.
* Trace that a circular attribute instance returned from evaluation case 2.
* @param value The value of the circular attribute instance.
* @param value The value of the circular attribute instance.
*/
*/
public void exitCircularCase2($ASTNode node, String attr, Object params, Object value) {
public void exitCircularCase2(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE2_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE2_RETURN,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular attribute instance returned from evaluation case 2.
* Trace that a circular attribute instance returned from evaluation case 2.
* @param value The value of the circular attribute instance.
* @param value The value of the circular attribute instance.
*/
*/
public void exitCircularCase3($ASTNode node, String attr, Object params, Object value) {
public void exitCircularCase3(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE3_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_CASE3_RETURN,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA entered evaluation case 1.
* Trace that a circular NTA entered evaluation case 1.
* @param value The value of the circular NTA.
* @param value The value of the circular NTA.
*/
*/
public void enterCircularNTACase1($ASTNode node, String attr, Object params, Object value) {
public void enterCircularNTACase1(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE1_START, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE1_START,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA in evaluation case 1 changed value.
* Trace that a circular NTA in evaluation case 1 changed value.
* @param value The value of the circular NTA, before and after.
* @param value The value of the circular NTA, before and after.
*/
*/
public void circularNTACase1Change($ASTNode node, String attr, Object params, Object value) {
public void circularNTACase1Change(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE1_CHANGE, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE1_CHANGE,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA returned from evaluation case 1.
* Trace that a circular NTA returned from evaluation case 1.
* @param value The value of the circular NTA.
* @param value The value of the circular NTA.
*/
*/
public void exitCircularNTACase1($ASTNode node, String attr, Object params, Object value) {
public void exitCircularNTACase1(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE1_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE1_RETURN,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA entered evaluation case 2.
* Trace that a circular NTA entered evaluation case 2.
* @param value The value of the circular NTA.
* @param value The value of the circular NTA.
*/
*/
public void enterCircularNTACase2($ASTNode node, String attr, Object params, Object value) {
public void enterCircularNTACase2(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE2_START, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE2_START,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA in evaluation case 2 changed value.
* Trace that a circular NTA in evaluation case 2 changed value.
* @param value The value of the circular NTA, before and after.
* @param value The value of the circular NTA, before and after.
*/
*/
public void circularNTACase2Change($ASTNode node, String attr, Object params, Object value) {
public void circularNTACase2Change(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE2_CHANGE, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE2_CHANGE,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA returned from evaluation case 2.
* Trace that a circular NTA returned from evaluation case 2.
* @param value The value of the circular NTA.
* @param value The value of the circular NTA.
*/
*/
public void exitCircularNTACase2($ASTNode node, String attr, Object params, Object value) {
public void exitCircularNTACase2(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE2_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE2_RETURN,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a circular NTA returned from evaluation case 2.
* Trace that a circular NTA returned from evaluation case 2.
* @param value The value of the circular NTA.
* @param value The value of the circular NTA.
*/
*/
public void exitCircularNTACase3($ASTNode node, String attr, Object params, Object value) {
public void exitCircularNTACase3(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE3_RETURN, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.CIRCULAR_NTA_CASE3_RETURN,
aspect,
node, attr, params, value);
}
}
/**
/**
...
@@ -323,50 +327,50 @@ public static class Trace {
...
@@ -323,50 +327,50 @@ public static class Trace {
* @param value The value of the node.
* @param value The value of the node.
*/
*/
public void copyNode($ASTNode node, Object value) {
public void copyNode($ASTNode node, Object value) {
receiver.accept($StateClass.Trace.Event.COPY_NODE, node, "ASTNode.copy", "", value);
receiver.accept($StateClass.Trace.Event.COPY_NODE,
ASPECT_AST,
node, "ASTNode.copy", "", value);
}
}
/**
/**
* Trace that an attribute was flushed.
* Trace that an attribute was flushed.
* @param value The value of the attribute.
* @param value The value of the attribute.
*/
*/
public void flushAttr($ASTNode node, String attr, Object params, Object value) {
public void flushAttr(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.FLUSH_ATTR, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.FLUSH_ATTR,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that an attribute was flushed by incremental evaluation.
* Trace that an attribute was flushed by incremental evaluation.
*/
*/
public void flushIncAttr($ASTNode node, String attr, Object params, Object value) {
public void flushIncAttr(
String aspect,
$ASTNode node, String attr, Object params, Object value) {
receiver.accept($StateClass.Trace.Event.INC_FLUSH_ATTR, node, attr, params, value);
receiver.accept($StateClass.Trace.Event.INC_FLUSH_ATTR,
aspect,
node, attr, params, value);
}
}
/**
/**
* Trace that a contribution check to a collection attribute begun.
* Trace that a contribution check to a collection attribute begun.
*/
*/
public void contributionCheckBegin($ASTNode node, String attr, String check) {
public void contributionCheckBegin(
String aspect,
$ASTNode node, String attr, String check) {
receiver.accept($StateClass.Trace.Event.CONTRIBUTION_CHECK_BEGIN, node, attr, check, "");
receiver.accept($StateClass.Trace.Event.CONTRIBUTION_CHECK_BEGIN,
aspect,
node, attr, check, "");
}
}
/**
/**
* Trace that a contribution check to a collection attribute ended.
* Trace that a contribution check to a collection attribute ended.
*/
*/
public void contributionCheckEnd($ASTNode node, String attr, String check) {
public void contributionCheckEnd(
String aspect,
$ASTNode node, String attr, String check) {
receiver.accept($StateClass.Trace.Event.CONTRIBUTION_CHECK_END, node, attr, check, "");
receiver.accept($StateClass.Trace.Event.CONTRIBUTION_CHECK_END,
aspect,
node, attr, check, "");
}
}
/**
/**
* Trace that a contribution check to a collection attribute found a match.
* Trace that a contribution check to a collection attribute found a match.
*/
*/
public void contributionCheckMatch($ASTNode node, String attr, String check, Object value) {
public void contributionCheckMatch(
String aspect,
$ASTNode node, String attr, String check, Object value) {
receiver.accept($StateClass.Trace.Event.CONTRIBUTION_CHECK_MATCH, node, attr, check, value);
receiver.accept($StateClass.Trace.Event.CONTRIBUTION_CHECK_MATCH,
aspect,
node, attr, check, value);
}
}
/**
/**
* Trace that a token was read.
* Trace that a token was read.
*/
*/
public void tokenRead($ASTNode node, String token, Object value) {
public void tokenRead($ASTNode node, String token, Object value) {
receiver.accept($StateClass.Trace.Event.TOKEN_READ, node, token, "", value);
receiver.accept($StateClass.Trace.Event.TOKEN_READ,
ASPECT_AST,
node, token, "", value);
}
}
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment