由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Java版 - java EL 问题请教
相关主题
求教:Facade Pattern vs Static Variable[合集] java 得 inner class 有没有 static 有什么区别啊?
这个怎么不对?问个可能比较奇怪的弱问题
JavaBean variable name standardinterview question:
how to solve the problem: the members change by each other .synchronized method does lock the object that passed into the method as a parameter?
问一个java的面试题 (转载)Javascript speed up
Re: Put classes into different files想说动同事用java而不是c++做新项目,大家能否列举一下优点?
error of unix redirecting command called by javamodify parameter, or return?
超级菜鸟问题:什末时候load classWhy java.lang.Iterable depends on java.util.Iterator
相关话题的讨论汇总
话题: file1话题: foreach话题: el话题: empty话题: filelist
进入Java版参与讨论
1 (共1页)
F**e
发帖数: 593
1
有没有办法把variable传给expression?
比如说一个简单的例子:

.. show something about this file1

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


.. show something about this file1


怎样才能把这个loop里的i传给这个file${i} 呢?上面这样不行啊。
l****3
发帖数: 8
2
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

F**e
发帖数: 593
3
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.

1 (共1页)
进入Java版参与讨论
相关主题
Why java.lang.Iterable depends on java.util.Iterator问一个java的面试题 (转载)
JSF 链接中的变量Re: Put classes into different files
Quick jdbc question, help needed, thx!error of unix redirecting command called by java
一个怪异的java 运行问题超级菜鸟问题:什末时候load class
求教:Facade Pattern vs Static Variable[合集] java 得 inner class 有没有 static 有什么区别啊?
这个怎么不对?问个可能比较奇怪的弱问题
JavaBean variable name standardinterview question:
how to solve the problem: the members change by each other .synchronized method does lock the object that passed into the method as a parameter?
相关话题的讨论汇总
话题: file1话题: foreach话题: el话题: empty话题: filelist