/** * Create a new arg-type-based PreparedStatementSetter using the args and types passed in. * <p>By default, we'll create an {@link ArgumentTypePreparedStatementSetter}. * This method allows for the creation to be overridden by subclasses. * @param args object array with arguments * @param argTypes int array of SQLTypes for the associated arguments * @return the new PreparedStatementSetter to use */ protected PreparedStatementSetter newArgTypePreparedStatementSetter(Object[] args, int[] argTypes) { return new ArgumentTypePreparedStatementSetter(args, argTypes); }
/** * Configures a {@link PreparedStatementSetter} that will use the Object [] as the * values to be set on the query to be executed for this reader. The int[] will * provide the types ({@link java.sql.Types}) for each of the values provided. * * @param args values to set on the query * @param types the type for each value in the args array * @return this instance for method chaining */ public JdbcCursorItemReaderBuilder<T> queryArguments(Object[] args, int[] types) { this.preparedStatementSetter = new ArgumentTypePreparedStatementSetter(args, types); return this; }
/** * Create a new arg-type-based PreparedStatementSetter using the args and types passed in. * <p>By default, we'll create an {@link ArgumentTypePreparedStatementSetter}. * This method allows for the creation to be overridden by subclasses. * @param args object array with arguments * @param argTypes int array of SQLTypes for the associated arguments * @return the new PreparedStatementSetter to use */ protected PreparedStatementSetter newArgTypePreparedStatementSetter(Object[] args, int[] argTypes) { return new ArgumentTypePreparedStatementSetter(args, argTypes); }
/** * Configures a {@link PreparedStatementSetter} that will use the Object [] as the * values to be set on the query to be executed for this reader. The int[] will * provide the types ({@link java.sql.Types}) for each of the values provided. * * @param args values to set on the query * @param types the type for each value in the args array * @return this instance for method chaining */ public JdbcCursorItemReaderBuilder<T> queryArguments(Object[] args, int[] types) { this.preparedStatementSetter = new ArgumentTypePreparedStatementSetter(args, types); return this; }