use of org.jdbi.v3.sqlobject.config.UseSqlParser in project jdbi by jdbi.
the class UseSqlParserImpl method configureForType.
@Override
public void configureForType(ConfigRegistry registry, Annotation annotation, Class<?> sqlObjectType) {
UseSqlParser anno = (UseSqlParser) annotation;
try {
final SqlParser parser = instantiate(anno.value(), sqlObjectType, null);
registry.get(SqlStatements.class).setSqlParser(parser);
} catch (Exception e) {
throw new IllegalStateException(e);
}
}
use of org.jdbi.v3.sqlobject.config.UseSqlParser in project jdbi by jdbi.
the class UseSqlParserImpl method configureForMethod.
@Override
public void configureForMethod(ConfigRegistry registry, Annotation annotation, Class<?> sqlObjectType, Method method) {
UseSqlParser anno = (UseSqlParser) annotation;
try {
final SqlParser parser = instantiate(anno.value(), sqlObjectType, method);
registry.get(SqlStatements.class).setSqlParser(parser);
} catch (Exception e) {
throw new IllegalStateException(e);
}
}
Aggregations