Interface MessageHandler

    • Method Detail

      • handle

        Message handle​(Connection connection,
                       Message message)
                throws FreeColException
        Handle an incoming message.
        Parameters:
        connection - The Connection the message arrived on.
        message - The Message to handle.
        Returns:
        A reply message, if any.
        Throws:
        FreeColException - if the message is malformed.
      • read

        Message read​(Connection connection)
              throws FreeColException,
                     javax.xml.stream.XMLStreamException
        Read an incoming Message.
        Parameters:
        connection - The Connection to read from.
        Returns:
        The Message found, or null if none.
        Throws:
        FreeColException - if the message can not be instantiated.
        javax.xml.stream.XMLStreamException - if there is a problem reading the message.