Re: Incorporating action interceptor configuration parameters into a message

2010-12-01 Thread Dave Newton
Nothing up my sleeve this time. It seems like a global property/constant would be usable, but I've never tried to @Inject a value into both interceptors and actions, so I have no idea if it'd work. Could be useful for a few usecases, though. Dave On Wed, Dec 1, 2010 at 11:38 AM, wrote: > Thank

Re: Incorporating action interceptor configuration parameters into a message

2010-12-01 Thread stanlick
Thanks Li -- This is what I was afraid of, but wanted to make sure I wasn't overlooking something a little more straightforward. Before duplicating the max size someplace else, I'll likely get into the Container build which reads the xml files. Somewhere in the back of my mind, it feels like I s

Re: Incorporating action interceptor configuration parameters into a message

2010-12-01 Thread Li Ying
I have read the source code of FileUploadInterceptor. I think it do the message getting in it's private method, and dose not use the maximumSize as a message format param. So I believe there is no simple way to "extract interceptor interceptor param". The simplest way I known is, hard coding the

Re: Incorporating action interceptor configuration parameters into a message

2010-12-01 Thread stanlick
Thanks Li -- I saw what the interceptor was doing and decided that was not going to work. Would you mind posting the "simple" technique to extract the parameter from the interceptor configuration. I'll admit I'm not a Guice pro and studying the container build sent me straight to the bar last ni

Re: Incorporating action interceptor configuration parameters into a message

2010-11-30 Thread Li Ying
The source code of FileUploadInterceptor is: http://svn.apache.org/repos/asf/struts/struts2/trunk/core/src/main/java/org/apache/struts2/interceptor/FileUploadInterceptor.java .. if (maximumSize != null && maximumSize < file.length()) {

Incorporating action interceptor configuration parameters into a message

2010-11-30 Thread stanlick
Before I wrap myself around my own axle, does anyone know a straightforward technique for substituting the maximumSize into a message property text according to the following scenario. 100123 image/png,image/x-png