Enum RemoteServerDisconnectEvent.Cause

java.lang.Object
java.lang.Enum<RemoteServerDisconnectEvent.Cause>
de.marcely.bedwars.api.event.remote.RemoteServerDisconnectEvent.Cause
All Implemented Interfaces:
Serializable, Comparable<RemoteServerDisconnectEvent.Cause>, java.lang.constant.Constable
Enclosing class:
RemoteServerDisconnectEvent

public static enum RemoteServerDisconnectEvent.Cause extends Enum<RemoteServerDisconnectEvent.Cause>
The reasons why no connection is further kept with this server.
  • Enum Constant Details

    • TIMEOUT

      public static final RemoteServerDisconnectEvent.Cause TIMEOUT
      We haven't received any ping responses since a while.

      Server possibly lost internet connection or stopped without notifiying about a SHUTDOWN.

    • SELF_TIMEOUT

      public static final RemoteServerDisconnectEvent.Cause SELF_TIMEOUT
      The remote server hasn't received any ping responses from us since a while and timed us out.

      This is a really rare edge case, but actually occurred in the past. Main reason is likely that the used protocol server was overloaded for a longer period.

    • SHUTDOWN

      public static final RemoteServerDisconnectEvent.Cause SHUTDOWN
      Server notified us that the connection loss is wanted.
    • RECONNECT

      public static final RemoteServerDisconnectEvent.Cause RECONNECT
      Server relogged while we thought that it was still alive.

      The RemoteServerConnectEvent will get called immediately after this event.

  • Method Details

    • values

      public static RemoteServerDisconnectEvent.Cause[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static RemoteServerDisconnectEvent.Cause valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null