Schnittstelle ServerConnection

Alle Superschnittstellen:
ClientSender
Alle bekannten Implementierungsklassen:
ServerConnectionMockup

public interface ServerConnection extends ClientSender
Interface representing a connection to the server. Extends ClientSender to allow sending messages to the server.
  • Methodenübersicht

    Modifizierer und Typ
    Methode
    Beschreibung
    void
    Establishes a connection to the server.
    void
    Disconnects from the server.
    boolean
    Checks if the client is currently connected to the server.

    Von Schnittstelle geerbte Methoden pp.battleship.game.client.ClientSender

    send
  • Methodendetails

    • isConnected

      boolean isConnected()
      Checks if the client is currently connected to the server.
      Gibt zurück:
      true if connected, false otherwise.
    • connect

      void connect()
      Establishes a connection to the server.
    • disconnect

      void disconnect()
      Disconnects from the server.