Syntax error, annotations are only available if source level is 1.5

Syntax error,annotations are only available if source level is 5.0
解决办法:Project->Properties->Java Compiler->Compiler Compliance Level选择5.0或者以上的jdk版本

你可能感兴趣的:(jdk,Annotations)