Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

123456789101112131415161718192021222324252627
  1. package events;
  2. import com.fasterxml.jackson.databind.JsonNode;
  3. import akka.actor.ActorRef;
  4. import structures.GameState;
  5. /**
  6. * A generic event processor interface, implemented by all classes that process events
  7. * sent from the user interface.
  8. * @author Dr. Richard McCreadie
  9. *
  10. */
  11. public interface EventProcessor {
  12. /**
  13. * The processEvent method takes as input the contents of the event in the form of a
  14. * Jackson JsonNode object, which contains a set of key-value pairs (the information
  15. * about the event). It also takes in a copy of an ActorRef object, which can be used
  16. * to send commands back to the front-end, and a reference to the GameState class,
  17. * which as the name suggests can be used to hold game state information.
  18. * @param message
  19. * @return
  20. */
  21. public void processEvent(ActorRef out, GameState gameState, JsonNode message);
  22. }