See: Description
| Class | Description |
|---|---|
| HibernateEngineFactory |
The implementation of the
SqlEngineFactory optimized for the Hibernate stack. |
| HibernateQuery |
The Hibernate stack implementation of the SQL Engine query contract.
|
| HibernateQuery.BatchResultHolder | |
| HibernateSession |
The Hibernate stack implementation of the SQL Engine session contract.
|
| HibernateSessionFactory |
The simple implementation of the factory
SqlSessionFactory for the Hibernate stack. |
| HibernateSimpleSession |
The Hibernate stack implementation of the SQL Engine session contract.
|
| HibernateWebSessionFactory |
The simple implementation of the factory
SqlSessionFactory for the Hibernate stack. |
HibernateEngineFactory sqlFactory = new HibernateEngineFactory();
sqlFactory.setMetaFilesNames("statements.qry"); // the meta statements file
SqlQueryEngine sqlEngine = sqlFactory.getQueryEngine("ALL_PEOPLE");
// for the case it runs on the top of the Hibernate stack
Configuration configuration = new Configuration().configure("hibernate.cfg.xml");
SqlSessionFactory sessionFactory = new HibernateSessionFactory(configuration.buildSessionFactory());
SqlSession session = sessionFactory.getSqlSession();
List<Person> list = sqlEngine.query(session, Person.class, null, SqlQueryEngine.ASC_ORDER);
For more info please see the Tutorials.
Copyright © 2016. All rights reserved.