View Javadoc
1 package net.sourceforge.backpedal.api.db; 2 3 import java.sql.PreparedStatement; 4 import java.sql.SQLException; 5 6 public interface BindVariable extends Cloneable { 7 /*** 8 * Call the relevant set() method on preparedStatement with index getIndex(). 9 */ 10 public void setInto(PreparedStatement preparedStatement) throws SQLException; 11 12 /*** 13 * Call the relevant set() method on preparedStatement but with a index 14 * override supplied 15 */ 16 public void setInto(int index, PreparedStatement preparedStatement) throws SQLException; 17 18 19 /*** 20 * Return the index of my position in the list of bind variables to which I belong. 21 */ 22 public int getIndex(); 23 24 /*** 25 * Return the value I represent i.e. that which will be passed to the 26 * set() method on the prepared statement passed to setInto(). 27 */ 28 public Object getValue(); 29 30 /*** 31 * Return the value from java.sql.Types that I represent. 32 */ 33 public int getSqlType(); 34 35 public void setIndex(final int index); 36 public void setValue(final Object value); 37 public void setColumnName(final String columnName); 38 39 public Object clone() throws CloneNotSupportedException; 40 41 public boolean isNull(); 42 43 /*** 44 * Return the name of the column I represent. Might be null is not known. 45 */ 46 public String getColumnName(); 47 48 49 }

This page was automatically generated by Maven