Tomcat 6: importing utility class from WEB-INF / classes

(I removed the client name because of the NDA)

Java / JSP newbie here. I have a JSP site and I have a Functions class in WEB-INF / src / client / project / Functions.java

In Functions.java function, package com.client.util

This is compiled and ends up as

WEB-INF/classes/client/project/Functions.class
WEB-INF/classes/client/project/Functions$1.class
WEB-INF/classes/client/project/Functions$RequestData.class

      

Now, in my index.jsp, I am trying to use this class like this:

<%@ page import="com.client.util.Functions"%><%
Functions.init(request,response,config,out);
%>

      

And I get the error "Functions could not be solved"

How can I customize my application in this function class?

I've tried adding various things to the web.xml but can't get it to work.

Thanks!

0


a source to share


1 answer


The directory where your classes are located does not match the package you are trying to import.



If the package is com.client.util

correct, it Functions.class

should be in the directory WEB-INF/classes/com/client/util/

.

+2


a source