Get rid of SourceVersion warnings

This commit is contained in:
Travis Burtrum 2018-09-25 23:53:58 -04:00
parent 6988a438ba
commit b04e9092d2

View File

@ -30,12 +30,6 @@ import static com.moparisthebest.jdbc.codegen.JdbcMapperFactory.SUFFIX;
*/ */
@SupportedAnnotationTypes("com.moparisthebest.jdbc.codegen.JdbcMapper.Mapper") @SupportedAnnotationTypes("com.moparisthebest.jdbc.codegen.JdbcMapper.Mapper")
@SupportedOptions({"jdbcMapper.databaseType", "jdbcMapper.arrayNumberTypeName", "jdbcMapper.arrayStringTypeName", "jdbcMapper.allowedMaxRowParamNames", "jdbcMapper.sqlCheckerClass"}) @SupportedOptions({"jdbcMapper.databaseType", "jdbcMapper.arrayNumberTypeName", "jdbcMapper.arrayStringTypeName", "jdbcMapper.allowedMaxRowParamNames", "jdbcMapper.sqlCheckerClass"})
//IFJAVA8_START
@SupportedSourceVersion(SourceVersion.RELEASE_8)
//IFJAVA8_END
/*IFJAVA6_START
@SupportedSourceVersion(SourceVersion.RELEASE_6)
IFJAVA6_END*/
public class JdbcMapperProcessor extends AbstractProcessor { public class JdbcMapperProcessor extends AbstractProcessor {
public static final Pattern paramPattern = Pattern.compile("\\{(([^\\s]+)\\s+(([Nn][Oo][Tt]\\s+)?[Ii][Nn]\\s+))?([BbCc][Ll][Oo][Bb]\\s*:\\s*([^:}]+\\s*:\\s*)?)?([^}]+)\\}"); public static final Pattern paramPattern = Pattern.compile("\\{(([^\\s]+)\\s+(([Nn][Oo][Tt]\\s+)?[Ii][Nn]\\s+))?([BbCc][Ll][Oo][Bb]\\s*:\\s*([^:}]+\\s*:\\s*)?)?([^}]+)\\}");
@ -80,6 +74,11 @@ public class JdbcMapperProcessor extends AbstractProcessor {
//out.println("JdbcMapperProcessor running!"); //out.println("JdbcMapperProcessor running!");
} }
@Override
public SourceVersion getSupportedSourceVersion() {
return SourceVersion.latestSupported();
}
@Override @Override
public synchronized void init(final ProcessingEnvironment processingEnv) { public synchronized void init(final ProcessingEnvironment processingEnv) {
super.init(processingEnv); super.init(processingEnv);