Package pl.com.bottega.ddd.annotations.event

Examples of pl.com.bottega.ddd.annotations.event.EventListener


    @Override
    public Object postProcessAfterInitialization(Object bean, String beanName) throws BeansException {
        if (!(bean instanceof SagaInstance)) {
            for (Method method : bean.getClass().getMethods()) {
              EventListener listenerAnnotation = method.getAnnotation(EventListener.class);             
               
              if (listenerAnnotation == null) {
                    continue;
                }
               
              Class<?> eventType = method.getParameterTypes()[0];
               
                if (listenerAnnotation.asynchronous()){
                  //TODO just a temporary fake impl
                  EventHandler handler = new AsynchronousEventHandler(eventType, beanName, method, beanFactory);
                  //TODO add to some queue
                  eventPublisher.registerEventHandler(handler);                 
                }
View Full Code Here

TOP

Related Classes of pl.com.bottega.ddd.annotations.event.EventListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.