Suggestion: improving EL-autocompletion for context attributes

How about defining attribute name<->bean-class pairs on request|session|application-context basis, so IDEA will be able to offer autocompletion/refactoring etc. in JSPs?

11 comments

This should suffice for it:
<jsp:useBean id="aaa" type="com.Controller" scope="request"/>

Yann Cebron wrote:

How about defining attribute name<->bean-class pairs on request|session|application-context basis, so IDEA will be able to offer autocompletion/refactoring etc. in JSPs?



--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

Thanks, but this will not work with Tiles, unless I include my "beans-defs.jsp" on each and every single page :(

0

This should suffice for it:
<jsp:useBean id="aaa" type="com.Controller"

&gt; scope="request"/>

<jsp:useBean/> isn't the only way to maka a bean available in a JSP page, however. It would be nice if there was for us to let IDEA know the type of a frequently-accessed bean -- I just can't think of one, however.

0

actually, I wanted autocompletion etc. for properties, not just for simple bean-names

0

If IDEA does not know type of initial context var then it could not
complete properties.

Yann Cebron wrote:

actually, I wanted autocompletion etc. for properties, not just for simple bean-names



--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

Actually, besides Struts bean:define, any custom tag supplying
'variables' should work.

Marcus Brito wrote:
>>This should suffice for it:
>><jsp:useBean id="aaa" type="com.Controller"


&gt; scope="request"/>

<jsp:useBean/> isn't the only way to maka a bean available in a JSP page, however. It would be nice if there was for us to let IDEA know the type of a frequently-accessed bean -- I just can't think of one, however.



--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

hmm maybe I'm doing something wrong here, but your example doesn't work in my setup. I only get completion for the bean name, "No suggestion" after the first '.' in "${beanName."

IDEA should be able to resolve the properties (at least in theory?!) knowing the bean class

0

You are not wrong, this particular issue fixed already in 5.0.3 / Demetra

Yann Cebron wrote:

hmm maybe I'm doing something wrong here, but your example doesn't work in my setup. I only get completion for the bean name, "No suggestion" after the first '.' in "${beanName."

IDEA should be able to resolve the properties (at least in theory?!) knowing the bean class



--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

There is ability to add post include page to each jsp file on the
jsp-property-group, however IDEA does not support it yet :(

Yann Cebron wrote:

Thanks, but this will not work with Tiles, unless I include my "beans-defs.jsp" on each and every single page :(


--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

You are not wrong, this particular issue fixed already in 5.0.3 / Demetra

And when can we expect it's release? It seems that pretty many features were solved since 5.0.1.

Thanks in advance,

Ahmed.

0

It's eap will start right after releasing 5.0.2.
We expect the RC build for 5.0.2 to release today/tomorrow.

Ahmed Mohombe wrote:
>> You are not wrong, this particular issue fixed already in 5.0.3 / Demetra


And when can we expect it's release? It seems that pretty many features
were solved since 5.0.1.

Thanks in advance,

Ahmed.



--
Best regards,
Maxim Mossienko
IntelliJ Labs / JetBrains Inc.
http://www.intellij.com
"Develop with pleasure!"

0

Please sign in to leave a comment.