Class CookieRequestEvent
java.lang.Object
com.velocitypowered.api.event.player.CookieRequestEvent
- All Implemented Interfaces:
ResultedEvent<CookieRequestEvent.ForwardResult>
@AwaitingEvent
public final class CookieRequestEvent
extends Object
implements ResultedEvent<CookieRequestEvent.ForwardResult>
This event is fired when a cookie from a client is requested either by a proxy plugin or
by a backend server. Velocity will wait on this event to finish firing before discarding the
cookie request (if handled) or forwarding it to the client.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classA result determining whether or not to forward the cookie request on.Nested classes/interfaces inherited from interface com.velocitypowered.api.event.ResultedEvent
ResultedEvent.ComponentResult, ResultedEvent.GenericResult, ResultedEvent.Result -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the result associated with this event.voidSets the result of this event.toString()
-
Constructor Details
-
CookieRequestEvent
Creates a new instance.- Parameters:
player- the player from whom the cookies is requestedkey- the identifier of the cookie
-
-
Method Details
-
getResult
Description copied from interface:ResultedEventReturns the result associated with this event.- Specified by:
getResultin interfaceResultedEvent<CookieRequestEvent.ForwardResult>- Returns:
- the result of this event
-
setResult
Description copied from interface:ResultedEventSets the result of this event. The result must be non-null.- Specified by:
setResultin interfaceResultedEvent<CookieRequestEvent.ForwardResult>- Parameters:
result- the new result
-
getPlayer
-
getOriginalKey
-
toString
-