All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.automationrockstars.bmo.event.processor.Action Maven / Gradle / Ivy

/*
 * 
 */

package com.automationrockstars.bmo.event.processor;

import com.automationrockstars.gunter.events.Event;

import static com.automationrockstars.bmo.event.processor.Message.Builder.newMessage;

public interface Action {

    public static final Action DO_NOTHING = new Action() {

        @Override
        public Message process(Event event) {
            return null;
        }
    };
    public static final Action PASS_TROUGH = new Action() {

        @Override
        public Message process(Event event) {
            return newMessage().withEvent(event);
        }

    };
    public static final Action STORE = new Action() {

        @Override
        public Message process(Event event) {
            EventStorage.storage().storeIfParentStored(event);
            return null;
        }
    };

    Message process(T event);
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy