Expression Language (EL)"

From Documentation
(Created page with '{{ZKDevelopersGuidePageHeader}} *Overview *Access Java Bean *[[ZUML_Expression Lang…')
 
m (correct highlight (via JWB))
 
(3 intermediate revisions by 3 users not shown)
Line 1: Line 1:
 
{{ZKDevelopersGuidePageHeader}}
 
{{ZKDevelopersGuidePageHeader}}
 +
{{Old Version
 +
|url=http://books.zkoss.org/wiki/ZK_Developer%27s_Reference/UI_Composing/ZUML/EL_Expressions
 +
|}}
 +
 +
==Overview==
 +
Like JSP<ref>Tutorial for EL in JSP http://java.sun.com/j2ee/1.4/docs/tutorial/doc/JSPIntro7.html</ref>, you could use Expression Language in ZUML pages. Expression Language is a scripting language. Through it, developer can write code in ZUML to access Java components (JavaBeans) easily. More than that, developer can access components in ZUML with simple and clear expression. EL can access implicit objects also. You can even import java methods to EL. Note that '''EL doesn't support "=" operator'''. Therefore, you can use EL to '''read value''', but '''not change value'''. EL also supports operators like <code>></code>,<code>==</code>,<code>+</code>,<code>-</code> , it can work with ZK attributes like <code>if</code> to provide sophisticated layout of components.
 +
 +
EL expressions use the syntax <code>${expr}</code>.
 +
 +
'''Notes'''
 +
<references/>
 +
 +
 +
{{ZKDevelopersGuideHeadingToc}}
  
*[[ZUML_Expression Language (EL)#Overview|Overview]]
 
*[[ZUML_Expression Language (EL)#Access_Java_Bean|Access Java Bean]]
 
*[[ZUML_Expression Language (EL)#Access_ZUML_Component|Access ZUML Component]]
 
*[[ZUML_Expression Language (EL)#Access_Implicit_Object|Access Implicit Object]]
 
*[[ZUML_Expression Language (EL)#More_EL_Examples|More EL Examples]]
 
*[[ZUML_Expression Language (EL)#Import_Java_Method's|Import Java Method's]]
 
  
 
{{ ZKDevelopersGuidePageFooter}}
 
{{ ZKDevelopersGuidePageFooter}}

Latest revision as of 10:36, 19 January 2022

Stop.png This documentation is for an older version of ZK. For the latest one, please click here.


Stop.png This documentation is for an older version of ZK. For the latest one, please click here.

Overview

Like JSP[1], you could use Expression Language in ZUML pages. Expression Language is a scripting language. Through it, developer can write code in ZUML to access Java components (JavaBeans) easily. More than that, developer can access components in ZUML with simple and clear expression. EL can access implicit objects also. You can even import java methods to EL. Note that EL doesn't support "=" operator. Therefore, you can use EL to read value, but not change value. EL also supports operators like >,==,+,- , it can work with ZK attributes like if to provide sophisticated layout of components.

EL expressions use the syntax ${expr}.

Notes





Last Update : 2022/01/19

Copyright © Potix Corporation. This article is licensed under GNU Free Documentation License.