The type List is not generic; it cannot be parameterized with arguments***
来源:互联网 发布:lumia拍照软件 编辑:程序博客网 时间:2024/06/07 02:45
今天在学习redis数据库时,下面一行代码遇到问题:
List<JedisShardInfo> shards = new ArrayList<JedisShardInfo>();
报的错误如下:
The type List is not generic; it cannot be parameterized with arguments <JedisShardInfo>
遇到这类问题的原因一般如下:我导入的list包:
import java.awt.List;不支持泛型,
解决办法:查看自己导入的list包,替换成下面的即可解决问题。
import java.util.List;
(补充)
AWT(Abstract Window Toolkit):抽象窗口工具集,是第一代的Java GUI组件,包含用于创建用户界面和绘制图形图像的所有分类。java.awt包
—–乐于分享,共同进步
—–Any comments greatly appreciated
阅读全文
0 0
- The type List is not generic; it cannot be parameterized with arguments
- The type List is not generic; it cannot be parameterized with arguments
- The type List is not generic; it cannot be parameterized with arguments
- The type List is not generic; it cannot be parameterized with arguments <Integer>
- the type List is not generic; it cannot be parameterized with arguments<T>解决办法
- 解决错误The type List is not generic; it cannot be parameterized with arguments <Map>
- The type List is not generic; it cannot be parameterized with arguments<T>
- The type List is not generic; it cannot be parameterized with arguments***
- The type JComboBox is not generic; it cannot be parameterized with arguments <String>错误
- Error: non-generic cannot be used with type arguments
- List is a raw type. References to generic type List<E> should be parameterized
- The type List is not generic
- “References to generic type List should be parameterized”
- List错误;The type List is not generic
- 关于java List的一个问题解决 - the type list is not generic
- The type List is not generic
- eclipse中如何去除警告:Class is a raw type. References to generic type Class<T> should be parameterized
- The project file .csproj cannot be opened." The project type is not supported by this installation.
- 【Scikit-Learn 中文文档】安装 scikit-learn | ApacheCN
- JS——解决API兼容问题(例1)
- 使用命令建MySQL数据库
- 各类机器学习问题的最优结果合集!附论文及实现地址索引
- 使用bannder实现轮播图
- The type List is not generic; it cannot be parameterized with arguments***
- Eclipse上创建一个Maven+Spring MVC的HelloWord项目2:发布项目
- Notes
- 【Scikit-Learn 中文文档】内核岭回归
- 一知半解学CubeMX——IIC:OLED屏显示
- 【Scikit-Learn 中文文档】广义线性模型
- Linux端安装python3.5.0开发环境
- 在RequestTracker(RT)里用msmtp通过远程smtp服务器465端口发邮件
- day6-jacascript-JS获取页面元素