Hi,
I am using Tapestry 5.0.1.5 and I have problem with using Symbols.
In a service, I need the version of tapestry currently run, so I
injected the TAPESTRY_VERSION symbol in the service constructor (see
the code below)
public class MyComponentEventResultProcessor implements
ComponentEventResultProcessor
private String tapestryVersion;
final RequestGlobals requestGlobals
public MyComponentEventResultProcessor(RequestGlobals requestGlobals,
@Symbol(SymbolConstants.TAPESTRY_VERSION) String tapestryVersion) {
this.requestGlobals = requestGlobals;
this.tapestryVersion = tapestryVersion;
}
public void processResultValue(Object value) throws IOException {
System
.out.println("MyComponentEventResultProcessor.processResultValue()
tapestryVersion = "+ tapestryVersion );
...
}
...
}
When the service method is called, then the output in the console is
not what I expected:
MyComponentEventResultProcessor.processResultValue() tapestryVersion =
MyComponentEventResultProcessor
The service is used to advice the AjaxComponentEventResultProcessor:
@Match("*ComponentEventResultProcessor")
public static void adviseAjaxRequest(
MethodAdviceReceiver receiver,
final RequestGlobals requestGlobals,
final MyComponentEventResultProcessor
myComponentEventResultProcessor) {
Did I do something wrong ? How can I solve/workaround this ?
Thank you.
-- Alessio