[jbosstools-issues] [JBoss JIRA] Commented: (JBIDE-1039) Seam Validator does not recognize valid boolean EL expressions
Alexey Kazakov (JIRA)
jira-events at lists.jboss.org
Mon Oct 8 09:09:05 EDT 2007
[ http://jira.jboss.com/jira/browse/JBIDE-1039?page=comments#action_12380949 ]
Alexey Kazakov commented on JBIDE-1039:
---------------------------------------
1. El Validator looks for every EL in files. e.g. <h:outputText value="{var.p"}>...</h:outputText>...
2. For each EL it makes request for our SeamELCompletionEngine. e.g. "#{var.p}"
3. Invokes SeamELCompletionEngine. That is almost the same request that Contetent Assist Procecor makes when user Ctrl+Click on "#{var1.p|}"
4. If SeamELCompletionEngine doesn't return any proposals then validator shows warning 'Illegal Expression'.
So validator does not parce EL at all.
What we can do:
1. Parce EL and try to resolve all variables and properties and ignore special words like "not", "null", "!=",... E.g. in "#{hotels != null and hotels.rowCount==0}" check "hotels" and "hotels.rowCount".
2. Parce a syntax of EL. E.g. "#{var1.p1 null var2.p2}" is not correct.
3. SeamELCompletionEngine should provide an information about resolved and unresolved sigments. E.g. there could be EL like "#{var1.p1.p2.p3.p4.p5.p6.p7}" and we have to provide name of a sigment (for example "p6") that we can't resolve to help validator to show an informative warning.
I think 1,3 are easier than 2.
> Seam Validator does not recognize valid boolean EL expressions
> --------------------------------------------------------------
>
> Key: JBIDE-1039
> URL: http://jira.jboss.com/jira/browse/JBIDE-1039
> Project: JBoss Tools
> Issue Type: Bug
> Components: JSF
> Affects Versions: 2.0.0.Beta4
> Reporter: Jacob Orshalick
> Assigned To: Alexey Kazakov
> Fix For: 2.0.0.CR1
>
>
> Seam Validator does not recognize boolean expressions in EL. For example, if I have the following:
> <h:panelGroup rendered="#{not empty search.results}">
> The "#{not empty search.results}" shows up as Illegal Expression even though this is valid EL. Thanks.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jbosstools-issues
mailing list