The javax.servlet.http package is part of the servlet API. Relevant jars can be found in Java EE containers (e.g. Sun Glassfish) or stand-alone servlet containers (e.g. Apache Tomcat). Essentially, these are Java web servers.
To compile code that depends on it, you will need to add a servlet library to your dependencies. Exactly how this is done depends on the tools you use.
Are you building a web application? (Is the expected output a .war or .ear file?) The source comes bundled with build.xml (possibly Ant build), any pom.xml files (possibly Maven build), or any .project/.classpath (maybe Eclipse project)?
The scenario is as follows. Asp.net 1.1 with javaapplet on the page calling the web service. The Javaapplet should determine the preferred user language in .net, you do HttpContext.Current.Request.UserLanguages โโ[0], so I asked and apparently in java the equivalent of request.getLocale ();
OK, ignore the above. To get Locale in an applet, I assume that you just use:
Locale userLocale = Locale.getDefault();
On the Java web server, you should use request.getLocale() to get the user locale from the HTTP request. Applets run on the client.
Mcdowell
source share