Пример #1
0
 private QueryBuilder<T, ID> checkQueryBuilderMethod(String methodName) throws SQLException {
   if (statementBuilder instanceof QueryBuilder) {
     return (QueryBuilder<T, ID>) statementBuilder;
   } else {
     throw new SQLException(
         "Cannot call " + methodName + " on a statement of type " + statementBuilder.getType());
   }
 }
Пример #2
0
 /** A short-cut for calling {@link QueryBuilder#prepare()}. */
 public PreparedQuery<T> prepare() throws SQLException {
   return statementBuilder.prepareStatement(null);
 }