HttpServletRequest cannot be resolved to a type。
问题描述:
HttpServletRequest cannot be resolved to a type。
Multiple markers at this line
- The import javax.servlet.http cannot be resolved
- The import javax.servlet.http cannot be resolved
- The import javax.servlet.http cannot be resolved
解决方案:
1.这个错误可能是服务器自带的servlet库未导入的原因。
2.右键项目属性,转到Targeted Runtimes,选择一个服务器,例如Tomcat,单击应用,可能就可以解决。
3.或者一开始建立项目就如下Targeted Runtimes

HttpServletRequest cannot be resolved to a type。的更多相关文章
- HttpServletRequest cannot be resolved to a type The superclass "javax.servlet.http.HttpServlet" was not found on the Java Build Path
HttpServletRequest cannot be resolved to a type The superclass "javax.servlet.http.HttpServlet& ...
- javax.servlet.jsp.JspException cannot be resolved to a type 和 javax.servlet.jsp.PageContext cannot be resolved to a type 解决办法
今天我从码云上拉一个项目下来,是个maven项目,闲来无事自己研究研究,发现刚拉下来,项目就有报错,我一看是httpServletRequest cannot be resolved to a typ ...
- maven中解决javax.servlet.jsp.PageContext cannot be resolved to a type
在eclipse环境下用maven出现:javax.servlet.jsp.PageContext cannot be resolved to a type. 这是由于没有引入jsp-api引发的问题 ...
- number (2)编译错 (类的大小写错误) Filewriter cannot be resolved to a type
没找到所使用的类所在的类定义,一般常见于使用了外部jar中的类,但有对应的import语句.比如,如果程序中使用了ArrayList这个类,但你程序类文件的最开始import部分如果没有import ...
- The type javax.servlet.http.HttpServletRequest cannot be resolved.
The type javax.servlet.http.HttpServletRequest cannot be resolved. It is indirectly referenced from ...
- eclipse报错:Multiple annotations found at this line: - String cannot be resolved to a type解决方法实测
Multiple annotations found at this line:- String cannot be resolved to a type- The method getContext ...
- ImageView cannot be resolved to a type
问题: ImageView cannot be resolved to a type 报这样的错误是没有加载MainActivity.java文件中加入 import android.widget.I ...
- myeclipse 开发环境下,提示 String cannot be resolved to a type
从SVN上下载项目,所有代码都有下来,在本地编译,java类总是报出n多红叉,惨不忍睹,String cannot be resolved to a type都出来了,以为是jar包未被加载,于是pr ...
- Eclipse “cannot be resolved to a type” 错误
eclipse中遇到了“XX cannot be resolved to a type”的报错信息.网上找了些资料,本文将做以简单总结. (1)jdk不匹配(或不存在) 项目指定的jdk为“j ...
随机推荐
- python模块安装报错 :error: command 'gcc' failed with exit status 1
参考:http://blog.csdn.net/fenglifeng1987/article/details/38057193 解决方法 yum install gcc libffi-devel py ...
- nmon进行性能分析
在压测的时候,搭配nmon,可以很好的记录机器cpu情况,内存情况 下载 需要下载nmon和nmon analyser,到各自的官网下载. nmon可以根据自己的操作系统版本下载二进制文件,免去安装. ...
- 用深度学习(DNN)构建推荐系统 - Deep Neural Networks for YouTube Recommendations论文精读
虽然国内必须FQ才能登录YouTube,但想必大家都知道这个网站.基本上算是世界范围内视频领域的最大的网站了,坐拥10亿量级的用户,网站内的视频推荐自然是一个非常重要的功能.本文就focus在YouT ...
- Scala 简介
Scala 特性 面向对象特性 Scala是一种纯面向对象的语言,每个值都是对象.对象的数据类型以及行为由类和特质描述. 类抽象机制的扩展有两种途径:一种途径是子类继承,另一种途径是灵活的混入机制.这 ...
- ETL实践--kettle转到hive
ETL实践--kettle只做源数据的抽取,其他数据转换转到hive上. 1.用hive代替kettle的数据关联的原因 (1).公司之前的数据ELT大量使用了kettle.用kettle导原始数据速 ...
- JS 获取字符串实际长度
解决思路,把中文转换为两个字节的英文,再计算长度. function getStrLength(str) { return str.replace(/[\u0391-\uFFE5]/g,"a ...
- Android语音识别--->>RecongnizerIntent实现
首先,咱得先说下注意点: Android中主要通过RecognizerIntent来实现语音识别,其实代码比较简单,但是如果找不到设置,就会抛出异常 ActivityNotFoundException ...
- Arch Linux安装记录
1.分区(MBR)# cfdisk 半图形界面,划分三个区:sda1 20G,sda2 80G,sda3 4G. 2.创建文件系统# mkfs.ext4 /dev/sda1# mkfs.ext4 /d ...
- 如何调用sklearn模块做交叉验证
终于搞明白了如何用sklearn做交叉验证!!! 一般在建立完模型之后,我们要预测模型的好坏,为了试验的可靠性(排除一次测试的偶然性)我们要进行多次测试验证,这时就要用交叉验证. sklearn中的s ...
- border-image详解
一.border-image的兼容性 border-image可以说是CSS3中的一员大将,将来一定会大放光彩,其应用潜力真的是非常的惊人.可惜目前支持的浏览器有限,仅Firefox3.5,chrom ...