Class PubSubConnectionStateEvent

java.lang.Object
com.github.philippheuer.events4j.core.domain.Event
com.github.twitch4j.pubsub.events.PubSubConnectionStateEvent
All Implemented Interfaces:
com.github.philippheuer.events4j.api.domain.IEvent

public class PubSubConnectionStateEvent extends com.github.philippheuer.events4j.core.domain.Event
PubSub Connection Event

Called when a PubSub socket's connection status changes.

  • Constructor Details

    • PubSubConnectionStateEvent

      public PubSubConnectionStateEvent(WebsocketConnectionState previousState, WebsocketConnectionState state, TwitchPubSub connection)
      Creates a new PubSubConnectionStateEvent instance.
      Parameters:
      previousState - The previous state of the websocket.
      state - The updated state of the websocket.
      connection - The PubSub instance whose connection status changed.
  • Method Details

    • getPreviousState

      public WebsocketConnectionState getPreviousState()
      The previous state of the websocket.
    • getState

      public WebsocketConnectionState getState()
      The updated state of the websocket.
    • getConnection

      public TwitchPubSub getConnection()
      The PubSub instance whose connection status changed.
    • toString

      public String toString()
      Overrides:
      toString in class com.github.philippheuer.events4j.core.domain.Event
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class com.github.philippheuer.events4j.core.domain.Event
    • canEqual

      protected boolean canEqual(Object other)
      Overrides:
      canEqual in class com.github.philippheuer.events4j.core.domain.Event
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class com.github.philippheuer.events4j.core.domain.Event