Class BaseHelper


  • @Component
    public class BaseHelper
    extends Object
    Core functionality needed in all members of SQL service family. Taken out of SqlBaseService in order to be accessible from other helpers without having to autowire SqlRepositoryServiceImpl (as it causes problems with Spring AOP proxies.)
    Author:
    lazyman, mederly
    • Constructor Detail

      • BaseHelper

        public BaseHelper()
    • Method Detail

      • getSessionFactory

        public org.hibernate.SessionFactory getSessionFactory()
      • setSessionFactory

        public void setSessionFactory​(org.hibernate.SessionFactory sessionFactory)
      • getSessionFactoryBean

        public org.springframework.orm.hibernate5.LocalSessionFactoryBean getSessionFactoryBean()
      • beginReadOnlyTransaction

        public org.hibernate.Session beginReadOnlyTransaction()
      • beginTransaction

        public org.hibernate.Session beginTransaction()
      • beginTransaction

        public org.hibernate.Session beginTransaction​(boolean readOnly)
      • cleanupSessionAndResult

        public void cleanupSessionAndResult​(org.hibernate.Session session,
                                            OperationResult result)
      • handleGeneralException

        public void handleGeneralException​(Throwable ex,
                                           org.hibernate.Session session,
                                           OperationResult result)
      • handleGeneralRuntimeException

        public void handleGeneralRuntimeException​(RuntimeException ex,
                                                  org.hibernate.Session session,
                                                  OperationResult result)
      • handleGeneralCheckedException

        public void handleGeneralCheckedException​(Throwable ex,
                                                  org.hibernate.Session session,
                                                  OperationResult result)