Class Message

java.lang.Object
it.fi.meucci.utils.Message

public class Message extends Object
Messages that are exchanged between client and server. They have a type, a recipient, and a sender. Contain an optional field called "content", used for various purposes, depending on the type of message. Has a static validate method that converts user input into a Message.
  • Constructor Details

    • Message

      public Message(Type type, String from, String to, ArrayList<String> args)
      Message Costructor
      Parameters:
      type - The Message type Type
      from - The sender
      to - The addressee
      args - Arguments of the message. They follow a different syntax depending on the type of the message
  • Method Details