package de.assecutor.votianlt.event;

import de.assecutor.votianlt.model.Message;
import org.springframework.context.ApplicationEvent;

/**
 * Event published when a new message is received from a client
 */
public class MessageReceivedEvent extends ApplicationEvent {

    private final Message message;

    public MessageReceivedEvent(Object source, Message message) {
        super(source);
        this.message = message;
    }

    public Message getMessage() {
        return message;
    }
}
