Yes, the problem is that you are advising every advisable
page/component/service in the system. This includes base classes; when
you've already advised the base class then the interface won't be
added and therefore the method won't exist in the transformation.
Try only adding the interface to clas
I always get IndexOutofBounds (methods.size == 0), though name is
equal (I logged that). Is there a bug in the matchMethods Impl?
Right... coding in email so I missed the different type signature.
Apparently findMethods has been deprecated in favor of
List matchMethods(Predicate predicate)
Fi
Right... coding in email so I missed the different type signature.
Apparently findMethods has been deprecated in favor of
List matchMethods(Predicate predicate)
Finds all methods matched by the provided predicate.
Which returns the TransformMethod which you want to add advice. Your
predicate woul
Sounds plausible, but how would a MethodFilter help? It can retrieve
the TransformMethodSignature, but how to use that to create an advise?
Hmm... just took a look at the code again and I think I see the problem.
/ This creates the method body if your class doesn't already implement it:
tra
Hmm... just took a look at the code again and I think I see the problem.
/ This creates the method body if your class doesn't already implement it:
transformation.addImplementedInterface(RequestParameterExtractor.class);
TransformMethodSignature extractMethod = new
TransformMethodSignature(Mo
@Christoph:
Same Error
@Josh
Yes, I also removed the Generic Map from the Interface.
Just checked in debug method: the method indeed already exists
(breakpoint: line 1443 InternalClassTransformationImpl). But how come?
Its never added through my code.
Did you take the type parameters off of
Did you take the type parameters off of the interface too (return a
raw map)? Have you looked at with a debugger? Stick a breakpoint right
before the exception and take a look at the methods in the ctclass.
I can't look at it now but I'll try to reproduce the problem tonight.
Josh
On Tue, Sep 1
Same error ?
2010/9/14 Markus Feindler
> Just tried, does not work :(.
>
> Have you tried without specify Generic types ?
>>
>> 2010/9/13 Christophe Cordenier
>>
>> Oh, this is maybe due to generics...
>>>
>>> 2010/9/13 Markus Feindler
>>>
>>>
public interface RequestParameterExtractor {
Just tried, does not work :(.
Have you tried without specify Generic types ?
2010/9/13 Christophe Cordenier
Oh, this is maybe due to generics...
2010/9/13 Markus Feindler
public interface RequestParameterExtractor {
Map extractRequestParameters();
}
is not equal to:
Transform
Will try that later and inform you.
>
> Original-Nachricht
> Datum: Tue, 14 Sep 2010 08:17:57 +0200
> Von: Christophe Cordenier
> An: Tapestry users
> Betreff: Re: Retrieve ActivationRequestParameters in custom
> PageResponseRenderer
>
Have you tried without specify Generic types ?
2010/9/13 Christophe Cordenier
> Oh, this is maybe due to generics...
>
> 2010/9/13 Markus Feindler
>
>>
>>
>> public interface RequestParameterExtractor {
>>Map extractRequestParameters();
>> }
>>
>> is not equal to:
>>
>>
>> TransformMeth
Oh, this is maybe due to generics...
2010/9/13 Markus Feindler
>
>
> public interface RequestParameterExtractor {
>Map extractRequestParameters();
> }
>
> is not equal to:
>
>
> TransformMethodSignature extractMethod = new
> TransformMethodSignature(Modifier.PUBLIC,
>"Map", "
public interface RequestParameterExtractor {
Map extractRequestParameters();
}
is not equal to:
TransformMethodSignature extractMethod = new
TransformMethodSignature(Modifier.PUBLIC,
"Map", "extractRequestParameters", null, null);
?
Everything looks good ... The only
Everything looks good ... The only thing i see is that the method signature
is not exactly the same as the one declared in the interface.
2010/9/13 Markus Feindler
> Am 13.09.2010 22:18, schrieb Thiago H. de Paula Figueiredo:
>
> On Mon, 13 Sep 2010 17:02:02 -0300, Christophe Cordenier <
>> ch
Am 13.09.2010 22:18, schrieb Thiago H. de Paula Figueiredo:
On Mon, 13 Sep 2010 17:02:02 -0300, Christophe Cordenier
wrote:
Please, Can you provide your Tapestry Module class that contributes your
worker ?
And the worker itself? It seems two different worker instances are
trying to add th
On Mon, 13 Sep 2010 17:02:02 -0300, Christophe Cordenier
wrote:
Please, Can you provide your Tapestry Module class that contributes your
worker ?
And the worker itself? It seems two different worker instances are trying
to add the same method to the same page class.
--
Thiago H. de Paul
2010 08:26:05 +0200
> > Von: Christophe Cordenier
> > An: Tapestry users
> > Betreff: Re: Retrieve ActivationRequestParameters in custom
> > PageResponseRenderer
> >
> > Weird, does you Index page extends a base class ?
> >
> > 20
Any ideas? Howard?
No, I get the exception for all pages, also the ExpcetionReportPage for
example.
Original-Nachricht
Datum: Thu, 9 Sep 2010 08:26:05 +0200
Von: Christophe Cordenier
An: Tapestry users
Betreff: Re: Retrieve ActivationRequestParameters in custom
No, I get the exception for all pages, also the ExpcetionReportPage for
example.
>
> Original-Nachricht
> Datum: Thu, 9 Sep 2010 08:26:05 +0200
> Von: Christophe Cordenier
> An: Tapestry users
> Betreff: Re: Retrieve ActivationRequestPa
Weird, does you Index page extends a base class ?
2010/9/8 Markus Feindler
> Sorry to bother you, but Im stuck with a DuplicateMemberException:
> Caused by: java.lang.RuntimeException:
> javassist.bytecode.DuplicateMemberException: duplicate method:
> extractRequestParameters in de.wiv.tapestry
Sorry to bother you, but Im stuck with a DuplicateMemberException:
Caused by: java.lang.RuntimeException:
javassist.bytecode.DuplicateMemberException: duplicate method:
extractRequestParameters in de.wiv.tapestryportlet2.pages.Index
at
org.apache.tapestry5.internal.services.InternalClassTr
Hi !
Tapestry 5.2 has a brand new API for class manipulation in worker, you have
to provide the method signature and implement the logic in a
ComponentMethodAdvice (see PropertyWorker sources to have a simple example)
HTH
2010/9/7 Markus Feindler
> So, I tried to follow your advice, but I don
So, I tried to follow your advice, but I don't see how to add a new
method after calling
"transformation.addImplementedInterface(MyInterface.class)". The
documentation states to use transformation.getOrCreateMethod, but where
to define the message body?
Actually,
I would implement a ClassTra
Actually,
I would implement a ClassTransformation and add it to
contributeComponentClassTransformWorker (see Tapestry Module), This worker
should add and implement an interface that contains the method to extract
useful information from the page
Then in your PageResponseRenderer, you can use Comp
Thats the class I discovered earlier at work.
Now my question is how to get ClassTransformation and
MutableComponentModel from the Page Object in the PageResponseRenderer?
Thanks for you help/hints.
Regards markus
Hi
Logic is enclosed in ActivationRequestParameterWorker, i think you can ad
On Mon, 06 Sep 2010 15:21:37 -0300, Christophe Cordenier
wrote:
Actually, not exactly, it uses an event handler to read values and add
them in the current link.
Thanks for the correction. :)
--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, dev
Actually, not exactly, it uses an event handler to read values and add them
in the current link.
2010/9/6 Thiago H. de Paula Figueiredo
> On Mon, 06 Sep 2010 15:01:09 -0300, Christophe Cordenier <
> christophe.corden...@gmail.com> wrote:
>
> Hi
>>
>
> Hi!
>
> Logic is enclosed in ActivationReq
On Mon, 06 Sep 2010 15:01:09 -0300, Christophe Cordenier
wrote:
Hi
Hi!
Logic is enclosed in ActivationRequestParameterWorker, i think you can
adapt this to your needs and extract values. At the moment, I don't see
any other way to identify ActivationRequestParameters during link
crea
Hi
Logic is enclosed in ActivationRequestParameterWorker, i think you can adapt
this to your needs and extract values. At the moment, I don't see any other
way to identify ActivationRequestParameters during link creation.
2010/9/6 Markus Feindler
>
>> i would say you can get them from
>> Reque
i would say you can get them from
Request directly
This only works for the current request. I need to get the parameters,
which will be set for the next request/redirect. It would be possible to
write get methods for the ActivationRequestParameters, but that would
not be the right way. I nee
Oh sorry, i had mis-read your first message. I didn't get deep into this new
feature at the time, but at first glance, i would say you can get them from
Request directly. Maybe, you can implement a worker that will be in charge
of implementing an interface that will contain the method that return t
Thats what Im doing right now for the PageActivationContext, but I also
need the values for the ActivationRequestParameters (introduced in 5.2:
http://tapestry.apache.org/tapestry5.2-dev/apidocs/org/apache/tapestry5/annotations/ActivationRequestParameter.html).
Hi
So why not passivate the page,
Hi
So why not passivate the page, see PageActivationContextCollector ? This is
how it works to create links.
2010/9/5 Markus Feindler
> No, Im trying to upgrade "my" portlet implementation from 5.1 to 5.2 and
> up to now the activationrequestparameters aren't put in the url, cause I
> have to
No, Im trying to upgrade "my" portlet implementation from 5.1 to 5.2
and up to now the activationrequestparameters aren't put in the url,
cause I have to adjust my former 5.1 custom response renderer. If the
Request is an ActionRequest (see Portlet lifecycle) you can't write
output into a stre
That's not enough details.
-- Josh
On Sep 5, 2010, at 9:51 AM, Markus Feindler wrote:
> Need it for portlet implementation.
>> Hi
>>
>> What is the purpose ? I guess you are dealing with some kind of dynamic
>> stuff, please can you give more details ?
>>
>> 2010/9/5 Markus Feindler
>>
>>>
Just curious, you try to include a portlet in a Tapestry page ?
2010/9/5 Markus Feindler
> Need it for portlet implementation.
>
> Hi
>>
>> What is the purpose ? I guess you are dealing with some kind of dynamic
>> stuff, please can you give more details ?
>>
>> 2010/9/5 Markus Feindler
>>
>>
I don't know if it suits to your case, but you could use
ComponentEventLinkEncoder to decode the request path... This will return you
an object from which you can extract activation context values.
Hope that helps
2010/9/5 Markus Feindler
> Need it for portlet implementation.
>
> Hi
>>
>> Wha
Need it for portlet implementation.
Hi
What is the purpose ? I guess you are dealing with some kind of dynamic
stuff, please can you give more details ?
2010/9/5 Markus Feindler
Hey folks,
I need to access page field values annotated with
ActivationRequestParameters in order to retrieve t
Hi
What is the purpose ? I guess you are dealing with some kind of dynamic
stuff, please can you give more details ?
2010/9/5 Markus Feindler
> Hey folks,
>
> I need to access page field values annotated with
> ActivationRequestParameters in order to retrieve the values. Reflection
> doesnt wo
Hey folks,
I need to access page field values annotated with
ActivationRequestParameters in order to retrieve the values. Reflection
doesnt work, because the fields are private and a
java.lang.IllegalAccessException is thrown. Whats the right way to
retrieve the values / activation request p
40 matches
Mail list logo