1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17 package javax.servlet.jsp.jstl.sql;
18
19 /***
20 * <p>This interface allows tag handlers implementing it to receive
21 * values for parameter markers ("?") in their SQL statements.</p>
22 *
23 * <p>This interface is implemented by both <sql:query> and
24 * <sql:update>. Its <code>addSQLParameter()</code> method
25 * is called by nested parameter actions (such as <sql:param>)
26 * to substitue <code>PreparedStatement<code> parameter values for
27 * "?" parameter markers in the SQL statement of the enclosing
28 * <code>SQLExecutionTag</code> action.</p>
29 *
30 * <p>The given parameter values are converted to their corresponding
31 * SQL type (following the rules in the JDBC specification) before
32 * they are sent to the database.</p>
33 *
34 * <p>Keeing track of the index of the parameter values being added
35 * is the responsibility of the tag handler implementing this
36 * interface</p>
37 *
38 * <p>The <code>SQLExcecutionTag</code> interface is exposed in order
39 * to support custom parameter actions which may retrieve their
40 * parameters from any source and process them before substituting
41 * them for a parameter marker in the sQL statement of the
42 * enclosing <code>SQLExecutionTag</code> action</p>
43 *
44 * @author Justyna Horwat
45 */
46 public interface SQLExecutionTag {
47
48 /***
49 * Adds a PreparedStatement parameter value
50 *
51 * @param the PreparedStatement parameter value
52 */
53 public void addSQLParameter(Object value);
54 }