public class StatementParameter
extends java.lang.Object
Title: Statement parameter
Description: An individual parameter for a parameterized SQL statement
Copyright: Copyright (c) 2004-2014, David Read
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
Modifier and Type | Field and Description |
---|---|
private java.lang.String |
dataString
Data value associated with an In or In-Out parameter
|
private int |
dataType
Parameter data type
|
static int |
IN
In parameter
|
static int |
IN_OUT
In-Out parameter
|
static int |
OUT
Out parameter
|
private int |
type
Parameter type (In, Out, In-Out)
|
Constructor and Description |
---|
StatementParameter(int aType,
int aDataType)
Create a new StatementParameter instance.
|
StatementParameter(int aType,
int aDataType,
java.lang.String aDataString)
Create a new StatementParameter instance.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getDataString()
Retrieve the value associated with this parameter.
|
int |
getDataType()
Retrieve the java.sql.Types value for this parameter
|
int |
getType()
Retrieve the direction (In/Out) of this parameter
|
public static final int IN
public static final int OUT
public static final int IN_OUT
private int type
private int dataType
private java.lang.String dataString
public StatementParameter(int aType, int aDataType)
aType
- The direction (In/Out) of the parameteraDataType
- The java.sql.Types value for the parameterpublic StatementParameter(int aType, int aDataType, java.lang.String aDataString)
aType
- The direction (In/Out) of the parameteraDataType
- The java.sql.Types value for the parameteraDataString
- The data supplied for this parameterpublic int getType()
public int getDataType()
public java.lang.String getDataString()