在Eclipse中.java文件报错:
Syntax error, parameterized types are only available if source level is 1.5 or greater
这个属于编译器版本的问题,解决方法:
1、右击项目-->Properties-->Java Compiler-->去掉Use compliance from executeion enveronment··的复选框,将Compiler ··改为1.5以上
2、Windows-->preferneces-->JAVA-->compiler-->右侧窗口"Compiler compliance level" 设置成1.5以上