1.1 --- a/java/sql-dk/src/info/globalcode/sql/dk/Parameter.java Sun Dec 15 20:25:15 2013 +0100
1.2 +++ b/java/sql-dk/src/info/globalcode/sql/dk/Parameter.java Sun Dec 15 22:07:51 2013 +0100
1.3 @@ -1,14 +1,32 @@
1.4 package info.globalcode.sql.dk;
1.5
1.6 +import java.sql.Types;
1.7 +
1.8 /**
1.9 *
1.10 * @author Ing. František Kučera (frantovo.cz)
1.11 */
1.12 public class Parameter {
1.13
1.14 + /**
1.15 + * @see Types
1.16 + */
1.17 + public static final int DEFAULT_TYPE = Types.VARCHAR;
1.18 private Object value;
1.19 private int type;
1.20
1.21 + public Parameter() {
1.22 + }
1.23 +
1.24 + public Parameter(Object value, Integer type) {
1.25 + this.value = value;
1.26 + if (type == null) {
1.27 + this.type = DEFAULT_TYPE;
1.28 + } else {
1.29 + this.type = type;
1.30 + }
1.31 + }
1.32 +
1.33 public Object getValue() {
1.34 return value;
1.35 }