Top Description Fields Constructors Methods
liquibase.database

public final Class PreparedStatementFactory

extends Object
Class Inheritance
Imports
liquibase.database.jvm.JdbcConnection, liquibase.exception.DatabaseException, java.sql.PreparedStatement

Factory for PreparedStatements

Field Summary

Modifier and TypeField and Description
private final JdbcConnection

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public PreparedStatement

Returns:

a PreparedStatement object representing the specified SQL statement
create
(String
the SQL statement to execute
sql
)

Creates a PreparedStatement object for the specified SQL statement.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAllwaitwaitwait

Field Detail

conback to summary
private final JdbcConnection con

Constructor Detail

PreparedStatementFactoryback to summary
public PreparedStatementFactory(JdbcConnection con)

Method Detail

createback to summary
public PreparedStatement create(String sql) throws DatabaseException

Creates a PreparedStatement object for the specified SQL statement. The SQL statement may be pre-compiled by the driver depending on its support.

Parameters
sql:String

the SQL statement to execute

Returns:PreparedStatement

a PreparedStatement object representing the specified SQL statement

Exceptions
DatabaseException:
if a database access error occurs or the given SQL statement is invalid
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Returns:String

a string representation of the object

Annotations
@Override