History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: IDEADEV-24406
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Normal Normal
Assignee: Maxim Mossienko
Reporter: Kenneth Christensen
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
IDEA: Development

Seam builtin and custom components are not resolved in JSF EL

Created: 21 Jan 08 21:39   Updated: 30 Jan 08 18:31
Component/s: J2EE.Seam
Fix Version/s: Diana 8243, Selena 7.0.3

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
File Attachments: None
Image Attachments:

1. jetbrains-example-identity-suggestions.jpg
(151 kb)

2. jetbrains-example-localeselector-suggestions.jpg
(131 kb)

3. jetbrains-example.jpg
(128 kb)

4. not-resolved.jpg
(26 kb)

Build: 7,656
Fixed in build: 7,676
Severity: Medium



 All   Comments   Work Log   Change History      Sort Order:
Maxim Mossienko - 22 Jan 08 01:12
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 - 22 Jan 08 01:26
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 IDEADEV-23078 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 - 22 Jan 08 13:42
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 - 22 Jan 08 14:47
Please see uploaded files.

Maxim Mossienko - 22 Jan 08 14:58
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 - 22 Jan 08 15:25
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 - 22 Jan 08 15:42
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 - 22 Jan 08 15:49
Do you have enough information to solve the problem (if possible) or do you need more information?

Maxim Mossienko - 22 Jan 08 16:08
I would really appreciate particular method names that are not resolved (except logout

Kenneth Christensen - 22 Jan 08 16:38
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'?