avatar
java EL 问题请教# Java - 爪哇娇娃
p*i
1
在前一段时间一直做梦,都是鬼怪之类的!在有一次,梦见自己翻了个山头,当时说不要去,可是自己不由的就翻过了山,看到 了一个寺庙,第一眼看到的是放生池,池里有乌龟还有鱼,但是鱼已经死了,乌龟在咬死鱼的肉吃,然后我就进大殿去绕着佛像转了一圈用手摸了一下,是檀木雕刻的金身,然后我就跪地三拜,又看了观音的法相也是檀木的,然后我就出了大殿上了山,准备离开回家,天却突然黑了,没有回家的路,然后我就准备去僧房借宿,在山顶俯瞰寺庙,突然脑袋很明亮起来,哪边是僧房,哪边是斋堂,里面摆设的是什么都在脑海浮现,一个声音说你终于回来了!我说这是哪里,声音回复我这里是玉佛寺!我就醒了!
avatar
F*e
2
有没有办法把variable传给expression?
比如说一个简单的例子:

.. show something about this file1

问题是我有10个这样的variable, file1, file2, ..., file10. 我可以用个forEach
loop


.. show something about this file1


怎样才能把这个loop里的i传给这个file${i} 呢?上面这样不行啊。
avatar
l*3
3
I think the easist way is to creat a colletion, either array or list,for
example, filelist to store your all variables, file1...file10, and then use


.....
make sure to save filelist as attribute to any of EL implicit object so EL can access it.

【在 F**e 的大作中提到】
: 有没有办法把variable传给expression?
: 比如说一个简单的例子:
:
: .. show something about this file1
:

: 问题是我有10个这样的variable, file1, file2, ..., file10. 我可以用个forEach
: loop
:
:
: .. show something about this file1

avatar
F*e
4
great idea. worked. Thank you so much. 5 baozi sent.

use
can access it.

【在 l****3 的大作中提到】
: I think the easist way is to creat a colletion, either array or list,for
: example, filelist to store your all variables, file1...file10, and then use
:
:
: .....
: make sure to save filelist as attribute to any of EL implicit object so EL can access it.

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。