package jist.swans.misc;

public abstract class MessageEvent extends Event {
  public Message data;
  public MessageAnno anno;
  
  public MessageEvent(int nodeId) {
    this.nodeId = nodeId;
  }

  public MessageEvent(boolean enabled) {
    super(enabled);
  }

  public final void handle(Message data, MessageAnno anno) {
    this.data = data;
    this.anno = anno;
    super.handle(nodeId);
  }

  public Message getData() {
    return data;
  }
}
