Package com.mewna.catnip.shard
Interface LifecycleEvent
public interface LifecycleEvent
- Since:
- 10/17/18.
- Author:
- amy
-
Nested Class Summary
-
Field Summary
Modifier and TypeFieldDescriptionstatic final EventType<ChunkingDone>
Fired when all guild chunking has been completed.Fired when the shard has connected to the websocket gateway, but has not yet sent an IDENTIFY payload.Fired when the shard is created and is about to connect to the websocket gateway.Fired when the shard has disconnected from the websocket gateway, and will (hopefully) be reconnecting.static final EventType<HighWebsocketLatency>
Fired whenever a shard's latency is higher than the value specified inCatnipOptions.highLatencyThreshold()
.Fired when the shard has successfully IDENTIFYd with the websocket gateway.static final EventType<MemberChunkRerequest>
Fired if manual member chunk re-requesting is enabled.static final EventType<RestRatelimitHit>
Fired whenever a REST route hits a ratelimit (HTTP 429).Fired when the shard has successfully RESUMEd with the websocket gateway.Fired when the shard's session is invalidated, be it from an OP 9 or other cause.static final EventType<GatewayClosed>
Fired when a shard's gateway websocket closes.static final EventType<GatewayConnectionFailed>
Fired when a shard fails to connect to Discord's websocket gateway.
-
Field Details
-
CONNECTING
Fired when the shard is created and is about to connect to the websocket gateway. The payload is a shard id / total pair. -
CONNECTED
Fired when the shard has connected to the websocket gateway, but has not yet sent an IDENTIFY payload. The payload is a shard id / total pair. -
DISCONNECTED
Fired when the shard has disconnected from the websocket gateway, and will (hopefully) be reconnecting. The payload is a shard id / total pair. -
IDENTIFIED
Fired when the shard has successfully IDENTIFYd with the websocket gateway. This is effectively the same as listening onDiscordEvent.READY
. The payload is a shard id / total pair. -
RESUMED
Fired when the shard has successfully RESUMEd with the websocket gateway. The payload is a shard id / total pair. -
SESSION_INVALIDATED
Fired when the shard's session is invalidated, be it from an OP 9 or other cause. -
CHUNKING_DONE
Fired when all guild chunking has been completed. -
MEMBER_CHUNK_REREQUEST
Fired if manual member chunk re-requesting is enabled. -
WEBSOCKET_CLOSED
Fired when a shard's gateway websocket closes. -
WEBSOCKET_CONNECTION_FAILED
Fired when a shard fails to connect to Discord's websocket gateway. -
REST_RATELIMIT_HIT
Fired whenever a REST route hits a ratelimit (HTTP 429). -
HIGH_WEBSOCKET_LATENCY
Fired whenever a shard's latency is higher than the value specified inCatnipOptions.highLatencyThreshold()
.
-