当前页面: 开发资料首页 → J2SE 专题 → 请教一个问题啊,大家开发JSTL标签库时,在ECLIPSE中怎么创建的
请教一个问题啊,大家开发JSTL标签库时,在ECLIPSE中怎么创建的
摘要: 请教一个问题啊,大家开发JSTL标签库时,在ECLIPSE中怎么创建的
有没有file-new类似这样方便的方法,
我不太懂,这些,感谢
请教一下。
路过,友情up...
顶
友情UP
顶
1.设置一个包里面写类com.hisys.tally.presentation.tags.ShipTallyFunction定义方法
EG.
public static String getShift(int s) {
String temp = "";
if (s == 2) temp = "中班";
if (s == 0) temp = "夜班";
if (s == 1) temp = "白班";
return temp;
}
2.然后再在JSP配置文件包WEB-INF里写配置文件xxx.tld把方法与标签名一一对应
getShift
getShift
com.hisys.tally.presentation.tags.ShipTallyFunction
java.lang.String getShift(int)
3. WEB.XML文件里面配置TAG
http://java.sun.com/jsp/jstl/core
/WEB-INF/c.tld
http://java.sun.com/jsp/jstl/fmt
/WEB-INF/fmt.tld
http://java.sun.com/jsp/jstl/fn
/WEB-INF/fn.tld
http://struts.apache.org/tags-html
/WEB-INF/struts-html.tld
http://hisys.com.cn/tags-app
/WEB-INF/app.tld
http://hisys.com.cn/tally
/WEB-INF/xxx.tld