struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Li Ying <liying.cn.2...@gmail.com>
Subject Re: Master-details JSP with Validation xml
Date Wed, 13 Oct 2010 04:44:02 GMT
Interface [Preparable] is another choice to implement
the data loading logic.

But, in some case, the data loading logic need to access the
parameters value to know what data should be loaded.
And, unfortunately, the interceptor [prepare] is configured
before interceptor [params] in the default interceptor stack.

see: [defaultStack] in this page:
http://struts.apache.org/2.2.1/docs/interceptors.html#Interceptors-TheDefaultConfiguration

Because of this interceptor order configuration, the Interface
[Preparable] should be executed before the interceptor [params].

So if you put your data loading logic in Interface [Preparable], then
it will be executed before you can
access parameters via the properties of Action.

I think this is inconvenient for me.


2010/10/13 Dave Newton <davelnewton@gmail.com>:
> Ugh, implementing Prepareable seems more palatable to me than throwing
> the same logic into somethingnthat returns the inputnresult name.
>
> Dave
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Mime
View raw message