org.skife.jdbi.v2.tweak
Interface StatementLocator

All Known Implementing Classes:
ClasspathStatementLocator, StringTemplate3StatementLocator

public interface StatementLocator

Used for finding the actual SQL for named statements..


Method Summary
 String locate(String name, StatementContext ctx)
          Use this to map from a named statement to SQL.
 

Method Detail

locate

String locate(String name,
              StatementContext ctx)
              throws Exception
Use this to map from a named statement to SQL. The SQL returned will be passed to a StatementRewriter, so this can include stuff like named params and whatnot.

Parameters:
name - The name of the statement, as provided to a Handle
Returns:
the SQL to execute, after it goes through a StatementRewriter
Throws:
Exception - if anything goes wrong, jDBI will percolate expected exceptions


Copyright © 2011. All Rights Reserved.