![]() |
![]() |
CommunityProduct
ContactPlease send mail to takezoe@aa.bb-east.ne.jp. |
Java Standard EL FunctionsJava Standard EL Functions(JSEL) provides standard EL functions for web application development. DownloadSource code is available on Subversion repository on SourceForge.jp. You can browse it using web browser at the following URL: Subversion repository URL is: LicenseHow to UseSetupPut functions-x.x.x.jar into WEB-INF/lib and add following filter definition to your web.xml. <filter> <filter-name>functionsFilter</filter-name> <filter-class>jp.sf.amateras.functions.filter.FunctionsFilter</filter-class> </filter> <filter-mapping> <filter-name>functionsFilter</filter-name> <url-pattern>*</url-pattern> <dispatcher>REQUEST</dispatcher> </filter-mapping> Add the following taglib directive to your JSP: <%@ taglib uri="http://amateras.sf.jp/functions" prefix="f" %> <%@ taglib uri="http://amateras.sf.jp/log4j" prefix="log" %> You can use EL functions which provided by JSEL: ${f:h(bean.property)} FunctionsA table of available EL functions are here: Core Functions (http://amateras.sf.jp/functions)
Log Functions (http://amateras.sf.jp/log4j)
These functions output log using Log4j. Logger name is decided by the following rules.
For example, /index.jsp is jsp.index, /admin/index.jsp is jsp.admin.index. Define appenders which are applied to these loggers in your log4j.properties or log4j.xml. ConfigurationSome EL functions such as f:date()、f:datetime()、f:time() have default format pattern. If you want to customize these patterns, create and put functions.properties into classpath root as the following contents. # Charset of URL encoding which used by f:u() defaultEncoding=UTF-8 # Format pattern of f:date() datePattern=yyyy/MM/dd # Format pattern of f:datetime() datetimePattern=yyyy/MM/dd HH:mm:ss # Format pattern of f:time() timePattern=HH:mm:ss Default functions.properties is contained by functions-x.x.x.jar. MavenYou can get JSEL from Maven repository which is provided by Project Amateras. Add the following fragment to your pom.xml. <repositories> <repository> <id>amateras</id> <name>Project AMateras Maven2 Repository</name> <url>http://amateras.sourceforge.jp/mvn/</url> </repository> </repositories> ... <dependencies> <dependency> <groupId>jp.sf.amateras.functions</groupId> <artifactId>functions</artifactId> <version>1.1.2</version> </dependency> </dependencies> History1.1.2 - 2011/01/19
1.1.1 - 2010/09/30
1.1.0 - 2010/03/16
1.0.0 - 2010/01/30Initial Release. |