this is my first time trying to use java for backend web systems.
I have been reading up some guides on how to do this, and thus far i understand the following points:
<%@ page language="java" import="twitter.*"%>
JavaFile jf = new Javafile();
String result = jf.searchTweets("someString");
type Exception report
description The server encountered an internal error () that prevented it from fulfilling this request.
org.apache.jasper.JasperException: An exception occurred processing JSP page /hello.jsp at line 10
7: <%@ page language="java" import="twitter.*"%>
10: Javafile jf = new JavaFile();
12: String result = jf.searchTweets("someString");
Only classes may be imported into a
.java file, and a JSP "compiles" to a
.java file, so this requirement holds for JSP files too.
From a quick glance at the API, it seems that your import is formatted correctly; but, you are importing the wrong namespace. The javadoc for the twitter4j API indicates that you should be importing "twitter4j" namespaces, not "twitter" namespaces.