Record Class TickerAction
java.lang.Object
java.lang.Record
dev.despical.tntrun.game.messages.TickerAction
public record TickerAction(TickerActionType type, net.kyori.adventure.text.Component message, net.kyori.adventure.text.Component title, net.kyori.adventure.text.Component subtitle, String sound)
extends Record
-
Constructor Summary
ConstructorsConstructorDescriptionTickerAction(TickerActionType type, net.kyori.adventure.text.Component message, net.kyori.adventure.text.Component title, net.kyori.adventure.text.Component subtitle, String sound) Creates an instance of aTickerActionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.net.kyori.adventure.text.Componentmessage()Returns the value of themessagerecord component.sound()Returns the value of thesoundrecord component.net.kyori.adventure.text.Componentsubtitle()Returns the value of thesubtitlerecord component.net.kyori.adventure.text.Componenttitle()Returns the value of thetitlerecord component.final StringtoString()Returns a string representation of this record class.type()Returns the value of thetyperecord component.
-
Constructor Details
-
TickerAction
public TickerAction(TickerActionType type, net.kyori.adventure.text.Component message, net.kyori.adventure.text.Component title, net.kyori.adventure.text.Component subtitle, String sound) Creates an instance of aTickerActionrecord class.- Parameters:
type- the value for thetyperecord componentmessage- the value for themessagerecord componenttitle- the value for thetitlerecord componentsubtitle- the value for thesubtitlerecord componentsound- the value for thesoundrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
type
Returns the value of thetyperecord component.- Returns:
- the value of the
typerecord component
-
message
public net.kyori.adventure.text.Component message()Returns the value of themessagerecord component.- Returns:
- the value of the
messagerecord component
-
title
public net.kyori.adventure.text.Component title()Returns the value of thetitlerecord component.- Returns:
- the value of the
titlerecord component
-
subtitle
public net.kyori.adventure.text.Component subtitle()Returns the value of thesubtitlerecord component.- Returns:
- the value of the
subtitlerecord component
-
sound
Returns the value of thesoundrecord component.- Returns:
- the value of the
soundrecord component
-