public interface ParameterMetaData
Modifier and Type | Field and Description |
---|---|
static int |
parameterModeIn
Indicates that the parameter mode is IN.
|
static int |
parameterModeInOut
Indicates that the parameter mode is INOUT.
|
static int |
parameterModeOut
Indicates that the parameter mode is OUT.
|
static int |
parameterModeUnknown
Indicates that the parameter mode is not known.
|
static int |
parameterNoNulls
Indicates that a parameter is not permitted to be NULL.
|
static int |
parameterNullable
Indicates that a parameter is permitted to be NULL.
|
static int |
parameterNullableUnknown
Indicates that whether a parameter is allowed to be null or not is not
known.
|
Modifier and Type | Method and Description |
---|---|
String |
getParameterClassName(int paramIndex)
Gets the fully-qualified name of the Java class which should be passed as
a parameter to the method
PreparedStatement.setObject . |
int |
getParameterCount()
Gets the number of parameters in the PreparedStatement for which this
ParameterMetaData contains information.
|
int |
getParameterMode(int paramIndex)
Gets the mode of the specified parameter.
|
int |
getParameterType(int paramIndex)
Gets the SQL type of a specified parameter.
|
String |
getParameterTypeName(int paramIndex)
Gets the database-specific type name of a specified parameter.
|
int |
getPrecision(int paramIndex)
Gets the number of decimal digits for a specified parameter.
|
int |
getScale(int paramIndex)
Gets the number of digits after the decimal point for a specified
parameter.
|
int |
isNullable(int paramIndex)
Gets whether null values are allowed for the specified parameter.
|
boolean |
isSigned(int paramIndex)
Gets whether values for the specified parameter can be signed numbers.
|
static final int parameterModeIn
static final int parameterModeInOut
static final int parameterModeOut
static final int parameterModeUnknown
static final int parameterNoNulls
static final int parameterNullable
static final int parameterNullableUnknown
String getParameterClassName(int paramIndex) throws SQLException
PreparedStatement.setObject
.paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happensint getParameterCount() throws SQLException
SQLException
- if a database error happensint getParameterMode(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happensint getParameterType(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happensString getParameterTypeName(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happensint getPrecision(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happensint getScale(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happensint isNullable(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error is encounteredboolean isSigned(int paramIndex) throws SQLException
paramIndex
- the index number of the parameter, where the first parameter
has an index of 1SQLException
- if a database error happens