Package org.mariadb.jdbc
Class SimpleParameterMetaData
- java.lang.Object
-
- org.mariadb.jdbc.SimpleParameterMetaData
-
- All Implemented Interfaces:
ParameterMetaData,Wrapper
public class SimpleParameterMetaData extends Object implements ParameterMetaData
Very basic info about the parameterized query, only reliable method is getParameterCount().
-
-
Field Summary
-
Fields inherited from interface java.sql.ParameterMetaData
parameterModeIn, parameterModeInOut, parameterModeOut, parameterModeUnknown, parameterNoNulls, parameterNullable, parameterNullableUnknown
-
-
Constructor Summary
Constructors Constructor Description SimpleParameterMetaData(int parameterCount)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetParameterClassName(int param)intgetParameterCount()intgetParameterMode(int param)intgetParameterType(int param)Parameter type are not sent by server.StringgetParameterTypeName(int param)intgetPrecision(int param)intgetScale(int param)intisNullable(int param)booleanisSigned(int param)booleanisWrapperFor(Class<?> iface)<T> Tunwrap(Class<T> iface)
-
-
-
Method Detail
-
getParameterCount
public int getParameterCount() throws SQLException- Specified by:
getParameterCountin interfaceParameterMetaData- Throws:
SQLException
-
isNullable
public int isNullable(int param) throws SQLException- Specified by:
isNullablein interfaceParameterMetaData- Throws:
SQLException
-
isSigned
public boolean isSigned(int param) throws SQLException- Specified by:
isSignedin interfaceParameterMetaData- Throws:
SQLException
-
getPrecision
public int getPrecision(int param) throws SQLException- Specified by:
getPrecisionin interfaceParameterMetaData- Throws:
SQLException
-
getScale
public int getScale(int param) throws SQLException- Specified by:
getScalein interfaceParameterMetaData- Throws:
SQLException
-
getParameterType
public int getParameterType(int param) throws SQLExceptionParameter type are not sent by server. See https://jira.mariadb.org/browse/CONJ-568 and https://jira.mariadb.org/browse/MDEV-15031- Specified by:
getParameterTypein interfaceParameterMetaData- Parameters:
param- parameter number- Returns:
- SQL type from java.sql.Types
- Throws:
SQLException- a feature not supported, since server doesn't sent the right information
-
getParameterTypeName
public String getParameterTypeName(int param) throws SQLException
- Specified by:
getParameterTypeNamein interfaceParameterMetaData- Throws:
SQLException
-
getParameterClassName
public String getParameterClassName(int param) throws SQLException
- Specified by:
getParameterClassNamein interfaceParameterMetaData- Throws:
SQLException
-
getParameterMode
public int getParameterMode(int param)
- Specified by:
getParameterModein interfaceParameterMetaData
-
unwrap
public <T> T unwrap(Class<T> iface) throws SQLException
- Specified by:
unwrapin interfaceWrapper- Throws:
SQLException
-
isWrapperFor
public boolean isWrapperFor(Class<?> iface) throws SQLException
- Specified by:
isWrapperForin interfaceWrapper- Throws:
SQLException
-
-