Class PulseBufferFlushEvent
java.lang.Object
org.bukkit.event.Event
dev.pulsemc.pulse.api.events.network.PulseBufferFlushEvent
Triggered when the PulseBuffer flushes accumulated packets to the network.
This event is not cancellable as the flush process has already started at the network layer.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.bukkit.event.Event
Event.Result -
Constructor Summary
ConstructorsConstructorDescriptionPulseBufferFlushEvent(Player player, FlushReason reason, int packetCount, long totalBytes) -
Method Summary
Modifier and TypeMethodDescriptionstatic HandlerListintGets the number of packets in this batch.Gets the player whose buffer was flushed.Gets the reason for the flush.longGets the size of the batch in bytes.Methods inherited from class org.bukkit.event.Event
callEvent, getEventName, isAsynchronous
-
Constructor Details
-
PulseBufferFlushEvent
-
-
Method Details
-
getPlayer
Gets the player whose buffer was flushed.- Returns:
- the player
-
getReason
Gets the reason for the flush.- Returns:
- flush reason
-
getPacketCount
public int getPacketCount()Gets the number of packets in this batch.- Returns:
- packet count
-
getTotalBytes
public long getTotalBytes()Gets the size of the batch in bytes.- Returns:
- size in bytes
-
getHandlers
- Specified by:
getHandlersin classEvent
-
getHandlerList
-