org.sqlproc.engine.spring
Class SpringSimpleSession

java.lang.Object
  extended by org.sqlproc.engine.spring.SpringSimpleSession
All Implemented Interfaces:
SqlSession

public class SpringSimpleSession
extends Object
implements SqlSession

The Spring stack implementation of the SQL Engine session contract. In fact it's a simple wrapper for the JdbcTemplate. It's the first parameter to all primary methods in the SqlQueryEngine and SqlCrudEngine.

The primary contract is the method for the SqlQuery instance creation.

For more info please see the Tutorials.

Author:
Vladimir Hudec

Field Summary
(package private)  org.springframework.jdbc.core.JdbcTemplate jdbcTemplate
          The Spring JdbcTemplate, the central class for all Spring database operations.
 
Constructor Summary
SpringSimpleSession(org.springframework.jdbc.core.JdbcTemplate jdbcTemplate)
          Creates a new instance.
 
Method Summary
 SqlQuery createSqlQuery(String queryString)
          
 org.springframework.jdbc.core.JdbcTemplate getJdbcTemplate()
          Returns the internal Spring JdbcTemplate instance.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

jdbcTemplate

org.springframework.jdbc.core.JdbcTemplate jdbcTemplate
The Spring JdbcTemplate, the central class for all Spring database operations.

Constructor Detail

SpringSimpleSession

public SpringSimpleSession(org.springframework.jdbc.core.JdbcTemplate jdbcTemplate)
Creates a new instance.

Parameters:
jdbcTemplate - the Spring JdbcTemplate instance
Method Detail

getJdbcTemplate

public org.springframework.jdbc.core.JdbcTemplate getJdbcTemplate()
Returns the internal Spring JdbcTemplate instance.

Returns:
the internal Spring JdbcTemplate instance

createSqlQuery

public SqlQuery createSqlQuery(String queryString)
                        throws SqlProcessorException

Specified by:
createSqlQuery in interface SqlSession
Throws:
SqlProcessorException


Copyright © 2011. All Rights Reserved.