Interface LastMessages

All Known Implementing Classes:
CircularFifoBufferLastMessages

public interface LastMessages
The LastMessages interface represents a collection of last messages in a chat application.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(String message)
    Adds a new message to the collection of last messages.
    void
    Clears all the last messages from the collection.
    Returns a collection of the last messages.
  • Method Details

    • clear

      void clear()
      Clears all the last messages from the collection.
    • add

      void add(String message)
      Adds a new message to the collection of last messages.
      Parameters:
      message - The message to be added.
    • getLastMessages

      Collection<String> getLastMessages()
      Returns a collection of the last messages.
      Returns:
      The collection of last messages.