/** * Used if you need to have some exotic parameter bound. * * @param position position to bindBinaryStream this argument, starting at 0 * @param argument exotic argument factory * * @return the same Query instance */ @SuppressWarnings("unchecked") public This bind(int position, Argument argument) { getBinding().addPositional(position, argument); return (This) this; }
/** * Register a positional output parameter * @param position the parameter position (zero-based) * @param sqlType an SQL type constant as defined by {@link java.sql.Types} or by the JDBC vendor. * @param mapper a mapper which converts the {@link CallableStatement} to a desired output type. * @return self */ public Call registerOutParameter(int position, int sqlType, CallableStatementMapper mapper) { getBinding().addPositional(position, new OutParamArgument(sqlType, mapper, null)); return this; }
private Binding positionalBinding(int size) { Binding b = new Binding(); for (int i = 0; i < size; i++) { b.addPositional(i, NOP); } return b; }
/** * Used if you need to have some exotic parameter bound. * * @param position position to bindBinaryStream this argument, starting at 0 * @param argument exotic argument factory * * @return the same Query instance */ @SuppressWarnings("unchecked") public This bind(int position, Argument argument) { getBinding().addPositional(position, argument); return (This) this; }
/** * Register a positional output parameter * @param position the parameter position (zero-based) * @param sqlType an SQL type constant as defined by {@link java.sql.Types} or by the JDBC vendor. * @param mapper a mapper which converts the {@link CallableStatement} to a desired output type. * @return self */ public Call registerOutParameter(int position, int sqlType, CallableStatementMapper mapper) { getBinding().addPositional(position, new OutParamArgument(sqlType, mapper, null)); return this; }