com.googlecode.jpattern.orm.session.datasource
Class DataSourceSession

java.lang.Object
  extended by com.googlecode.jpattern.orm.session.ASession
      extended by com.googlecode.jpattern.orm.session.datasource.DataSourceSession
All Implemented Interfaces:
ISession, ISessionSqlPerformer

public class DataSourceSession
extends ASession

Author:
Francesco Cina 21/mag/2011

Constructor Summary
DataSourceSession(DataSource dataSource, IOrmClassToolMap ormClassToolMap)
           
 
Method Summary
 ITransaction beginTransaction()
          Open a new Transaction
 void close()
          Close the current session and release the connection to the database.
 ISqlPerformer sqlPerformer()
          Return an executor to perform plain sql queries.
 
Methods inherited from class com.googlecode.jpattern.orm.session.ASession
delete, delete, delete, delete, find, find, findQuery, findQuery, findQuery, findQuery, getOrmClassToolMap, save, save, scriptExecutor, sqlExecutor, update, update, update, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DataSourceSession

public DataSourceSession(DataSource dataSource,
                         IOrmClassToolMap ormClassToolMap)
Method Detail

beginTransaction

public ITransaction beginTransaction()
                              throws OrmException
Description copied from interface: ISession
Open a new Transaction

Returns:
Throws:
OrmException

close

public void close()
           throws OrmException
Description copied from interface: ISession
Close the current session and release the connection to the database.

Throws:
OrmException

sqlPerformer

public ISqlPerformer sqlPerformer()
                           throws OrmException
Description copied from interface: ISessionSqlPerformer
Return an executor to perform plain sql queries.

Returns:
Throws:
OrmException


Copyright © 2011. All Rights Reserved.