Class EventHandler

  • All Implemented Interfaces:
    java.util.EventListener, org.aopalliance.aop.Advice, org.aopalliance.intercept.Interceptor, org.aopalliance.intercept.MethodInterceptor, org.springframework.context.ApplicationListener<ContextMessage>

    public class EventHandler
    extends java.lang.Object
    implements org.aopalliance.intercept.MethodInterceptor, org.springframework.context.ApplicationListener<ContextMessage>
    method interceptor responsible for login and creation of Events. Calls are made to the BasicSecuritySystem provided in the constructor. After the method is invoked various cleanup actions are performed and finally all credentials all cleared from the Thread.
    Since:
    3.0
    • Field Detail

      • txSource

        protected final org.springframework.transaction.interceptor.TransactionAttributeSource txSource
      • sql

        protected final ome.util.SqlAction sql
      • readOnly

        protected final boolean readOnly
    • Constructor Detail

      • EventHandler

        @Deprecated
        public EventHandler​(ome.util.SqlAction sql,
                            BasicSecuritySystem securitySystem,
                            SessionFactory factory,
                            org.springframework.transaction.interceptor.TransactionAttributeSource txSource)
        Deprecated.
        only public constructor, used for dependency injection. Requires an active HibernateTemplate and BasicSecuritySystem.
        Parameters:
        sql - the SQL action
        securitySystem - the security system
        factory - the Hibernate session factory
        txSource - the Spring transaction attribute source
    • Method Detail

      • invoke

        public java.lang.Object invoke​(org.aopalliance.intercept.MethodInvocation arg0)
                                throws java.lang.Throwable
        Invocation interceptor for preparing this Thread for execution and subsequently resetting it.
        Specified by:
        invoke in interface org.aopalliance.intercept.MethodInterceptor
        Throws:
        java.lang.Throwable
        See Also:
        MethodInterceptor.invoke(org.aopalliance.intercept.MethodInvocation)
      • doLogin

        public boolean doLogin​(boolean readOnly,
                               boolean isClose)