Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Web Tools Project (WTP) » JSP validation and Struts tags
JSP validation and Struts tags [message #189381] Wed, 07 March 2007 14:47 Go to next message
Rémi Cocula is currently offline Rémi Cocula
Messages: 3
Registered: July 2009
Junior Member
Hi,

I use WTP to develop a struts application.

I often use the bean:define tag that creates a reference with an object in
any scope.

for exemple :

<bean:define id="foo" name="fooKey" type="java.lang.String" />

<% foo = "another foo" %>

This works as the bean:define tag actually creates a foo reference in the
page scope.

The problem is that the WTp JSP validator issues an error with "foo can
not be resolved".

Does anyone have an idea of how to avoid this error ?
Re: JSP validation and Struts tags [message #189575 is a reply to message #189381] Sun, 11 March 2007 10:17 Go to previous messageGo to next message
Eclipse User
Originally posted by: casper.casper.casper

Hi,

> The problem is that the WTp JSP validator issues an error with "foo can
> not be resolved".


I have this same problem, its with a custom tag I wrote my own, but it
actually is with any tag.

Example, of my JSP:

<dh:mytag id="myvar" .../>

then in my JSP after the tag I put the snippet
<%= myvar %>

the code actually WORKS, but the JSP editor in eclipse says theres an error:
cannot resolve "myvar"

My eclipse version is:
Version: 3.2.2

Build id: M20070212-1330

Web Standard Tools - Web Core


Version: 1.5.3.v200701251933--4hNDDhFfKVFaSL

Build id: 200702082048
Re: JSP validation and Struts tags [message #189611 is a reply to message #189575] Mon, 12 March 2007 09:53 Go to previous messageGo to next message
Nitin Dahyabhai is currently offline Nitin Dahyabhai
Messages: 2310
Registered: July 2009
Senior Member
Casper wrote:
>> The problem is that the WTp JSP validator issues an error with "foo can
>> not be resolved".
>
>
> I have this same problem, its with a custom tag I wrote my own, but it
> actually is with any tag.
>
> Example, of my JSP:
>
> <dh:mytag id="myvar" .../>
>
> then in my JSP after the tag I put the snippet
> <%= myvar %>
>
> the code actually WORKS, but the JSP editor in eclipse says theres an error:
> cannot resolve "myvar"

In both of these cases a TagExtraInfo class needs to be declared
that returns information stating that the id/name attributes end up
creating local Java variables along with the correct scopes. The
JSP editor will attempt to load that class and talk to it, but it
has limitations when doing so, among them that the VM running
Eclipse must be able to read the class file--no running Eclipse with
1.4 and using a tag library compiled for 1.5.

--
Nitin Dahyabhai
Structured Source Editor


---
Nitin Dahyabhai
Eclipse WTP, IBM
Re: JSP validation and Struts tags [message #189789 is a reply to message #189611] Thu, 15 March 2007 08:41 Go to previous messageGo to next message
Eclipse User
Originally posted by: nomail.xxxxxxxx.com

I doesnt depend on the JVM version.
I tested this on another IDE with JVM 1.4 and it works correctly.

I think it's some sort of bug or misconfiguration of Eclipse WTP.
Re: JSP validation and Struts tags [message #190064 is a reply to message #189381] Sat, 17 March 2007 15:32 Go to previous messageGo to next message
Eclipse User
Originally posted by: casper.casper.casper

no one knows ?
Re: JSP validation and Struts tags [message #190217 is a reply to message #189789] Wed, 21 March 2007 02:36 Go to previous messageGo to next message
Nitin Dahyabhai is currently offline Nitin Dahyabhai
Messages: 2310
Registered: July 2009
Senior Member
Giovanni P. wrote:
> I doesnt depend on the JVM version.
> I tested this on another IDE with JVM 1.4 and it works correctly.
>
> I think it's some sort of bug or misconfiguration of Eclipse WTP.

Actually, in WTP it does depend on the JVM version somewhat--I can't
tell you how other IDEs manage it. Glamoute, is your project's
directory directly under the workspace folder or is it elsewhere?
You might be affected by bug 178443.

https://bugs.eclipse.org/bugs/show_bug.cgi?id=178443

--
Nitin Dahyabhai
Structured Source Editor


---
Nitin Dahyabhai
Eclipse WTP, IBM
Re: JSP validation and Struts tags [message #190524 is a reply to message #190217] Wed, 28 March 2007 07:38 Go to previous message
Eclipse User
Originally posted by: casper.casper.casper

nevertheless it is a bug, since the wtp jsp editor reports an error
whereas the code acually works correctly.


thank you
Previous Topic:Dali plugin (JPA)
Next Topic:No editor descriptor for id
Goto Forum:
  


Current Time: Sat Oct 25 00:02:05 GMT 2014

Powered by FUDForum. Page generated in 0.01965 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software