Project
IntelliJ IDEA
Priority
Normal
Type
Bug
Fix versions
No Fix versions
State
Fixed
Assignee
Maxim Mossienko
Subsystem
J2EE.Seam
Affected versions
No Affected versions
Fixed in build
108.65  
  • Created by   Kenneth Christensen
    4 years ago (21 Jan 2008 22:39)
  • Updated by   root
    2 years ago (17 Jan 2010 20:57)
  • Jira: IDEADEV-24406
    (history, comments)
 
IDEA-42613 Seam builtin and custom components are not resolved in JSF EL
0
Issue is visible to: All Users
  The issue is visible to the selected user group only
Comments (10)
 
History
 
Linked Issues (?)
 
Maxim Mossienko
  Maxim Mossienko
22 Jan 2008 02:12
4 years ago
I took blog example from Seam 2.0.1 CR and had builtin vars resolved.
Please note tag, that IDEA creates builtin variables on analysis of components.xml e.g.
identity variable is added when components.xml has tag <security:identity />
localSelector variable is added upon presence of <core:resource-loader/> in the same config file
Kenneth Christensen
  Kenneth Christensen
22 Jan 2008 02:26
4 years ago
I use this components.xml file:

<?xml version="1.0" encoding="UTF-8"?>

<components xmlns="http://jboss.com/products/seam/components"
xmlns:core="http://jboss.com/products/seam/core"
xmlns:mail="http://jboss.com/products/seam/mail"
xmlns:security="http://jboss.com/products/seam/security"
xmlns:web="http://jboss.com/products/seam/web"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://jboss.com/products/seam/components http://jboss.com/products/seam/components-2.0.xsd
http://jboss.com/products/seam/core http://jboss.com/products/seam/core-2.0.xsd
http://jboss.com/products/seam/mail http://jboss.com/products/seam/mail-2.0.xsd
http://jboss.com/products/seam/security http://jboss.com/products/seam/security-2.0.xsd
http://jboss.com/products/seam/web http://jboss.com/products/seam/web-2.0.xsd">
<core:init debug="true" jndi-pattern="sine/#{ejbName}/local" transaction-management-enabled="false"/>

<core:manager conversation-timeout="120000" conversation-id-parameter="cid"/>

<core:resource-loader>
<core:bundle-names>
<value>sine</value>
<value>messages</value>
</core:bundle-names>
</core:resource-loader>

<security:identity authenticate-method="#{authenticatorService.authenticate}"/>
<mail:mail-session session-jndi-name="java:/Mail"/>

<web:character-encoding-filter encoding="UTF-8" override-client="true" url-pattern="*.jspx"/>
<web:redirect-filter url-pattern="*.jspx"/>
<!--<web:multipart-filter create-temp-files="false" max-request-size="524288" url-pattern="*.jspx"/>-->
<web:multipart-filter create-temp-files="false" url-pattern="*.jspx"/>
<web:exception-filter url-pattern="*.jspx"/>
</components>

and as I mentioned in IDEA-41497 IDEA only resolves some of the builtin (also custom) methods.
This is really strange if it works for you and not for me :-(
Maxim Mossienko
  Maxim Mossienko
22 Jan 2008 14:42
4 years ago
Does IDEA highlight following file properly?
<!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core"
template="#{theme.template}">

<ui:define name="content">
<div class="blogEntry">
<h:form>
<div>
<h:outputLabel for="password">Password:</h:outputLabel>
</div>
<div>
<h:inputSecret id="password"
value="#{identity.password}"
size="15"
maxlength="15"/>
<h:commandButton value="Login"/>
<h:commandLink styleClass="languageSelectorLink" value="EN" action="#{localeSelector.selectLanguage('en')}"/>
<span class="errors"><h:message for="password"/></span>
<span class="errors"><h:messages globalOnly="true"/></span>
</div>
</h:form>
</div>
</ui:define>

</ui:composition>
Kenneth Christensen
  Kenneth Christensen
22 Jan 2008 15:47
4 years ago
Please see uploaded files.
Maxim Mossienko
  Maxim Mossienko
22 Jan 2008 15:58
4 years ago
IDEA adds Seam specific variables on presence of 'xmlns:ui="http://java.sun.com/jsf/facelets"' in root tag. Do you have such declaration?
Kenneth Christensen
  Kenneth Christensen
22 Jan 2008 16:25
4 years ago
Yes, all jspx files have such declaration.

The really strange part of this issue, is that IDEA resolves some of the methods but not all of them.
Maxim Mossienko
  Maxim Mossienko
22 Jan 2008 16:42
4 years ago
this observation completely changes the problem (if only certain methods are not resolved):
actually IDEA shows methods that have signature as specified in attribute definition e.g.
'action' attribute (e.g. in ) should have method signature 'java.lang.Object action()' and logout method in identity has void return type
Kenneth Christensen
  Kenneth Christensen
22 Jan 2008 16:49
4 years ago
Do you have enough information to solve the problem (if possible) or do you need more information?
Maxim Mossienko
  Maxim Mossienko
22 Jan 2008 17:08
4 years ago
I would really appreciate particular method names that are not resolved (except logout :)
Kenneth Christensen
  Kenneth Christensen
22 Jan 2008 17:38
4 years ago
At the moment I can't :-( because I don't have an overview of all the 'missing' method names.
And also some of my own (custom) Seam components are not resolved 100%.

'localeSelector' suggestions box is empty but it looks like it's resolved in some way, because some of the methods is
not flagged as error in the editor - see jetbrains-example-localeselector-suggestions.jpg

Would it be possible to scan all sourcefiles (background task - or when you edit a file) with a @name annotation and include all public methods in the IDEA 'Seam suggestions library'?