Package org.hibernate.resource.jdbc.spi
Interface StatementInspector
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
EmptyStatementInspector
,SQLStatementInspector
Implementors may inspect and even process each SQL command issued
by a session, before a JDBC
statement is prepared. A
StatementInspector
may be either:
- shared by all sessions created by a given session factory, in which case it must be thread-safe, or
- a dedicated instance registered for a certain session.
An implementation may be specified via the configuration property "hibernate.session_factory.statement_inspector". An implementation registered this way is shared between sessions.
-
Method Summary
-
Method Details
-
inspect
Inspect the given SQL command, possibly returning a different SQL command to be used instead. Anull
return value is interpreted as if the method had returned its argument.- Parameters:
sql
- The SQL to inspect- Returns:
- The processed SQL to use; may be
null
-