Skip to main content



      Home
Home » Language IDEs » ServerTools (WTP) » Help: JSP, EL and code assist
Help: JSP, EL and code assist [message #638719] Fri, 12 November 2010 05:18
Eclipse UserFriend
Hello,
I have a question about WTP support to EL code assist: I don't kow if it
exists and, if so, how is it supposed to work. Reading on the bug
reports it would seem that some sort of support does exist...

I mean, suppose I have a Dynamic Web Project with the following Java class:

package test;

public class MyClass
{
public String getStringProperty()
{
return "Hello World";
}
}

Now, suppose I have a JSP like this:

<%@page import="test.MyClass"%>
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%
MyClass myc = new MyClass();
pageContext.setAttribute("myc", myc);
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<c:out value="${myc.stringProperty}"></c:out>
</body>
</html>

(of course, I have the JARs for JSTL in the classpath and the needed
TLDs mapped in web.xml)

In other words, I want to print the value of "stringProperty" property
of my MyClass instance, which is previously saved in the pageContext in
the provided scriptlet.

Then, if I try code completion on {$myc.stringProperty}, either for the
context key name or for the property name, it does not work.

So, is it supposed to work? Are there other cases in which code assist
support for EL is supported?

Thanks in advance,
Mauro.
Previous Topic:JSDT or Aptana or MyEclipse ?
Next Topic:Problem Using Eclipse WTP\Tomcat\CXF to Dev Web Service
Goto Forum:
  


Current Time: Sat Jul 05 06:05:47 EDT 2025

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

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

Back to the top