Record Class Notification
java.lang.Object
java.lang.Record
net.minestom.server.advancements.notifications.Notification
@Deprecated(since="1.4.1",
forRemoval=true)
public record Notification(@NotNull Component title, @NotNull FrameType frameType, @NotNull ItemStack icon)
extends Record
Deprecated, for removal: This API element is subject to removal in a future version.
Represents a message which can be sent using the
NotificationCenter
.- Since:
- 1.0.0
-
Constructor Summary
ConstructorDescriptionNotification
(@NotNull Component title, @NotNull FrameType frameType, @NotNull ItemStack icon) Deprecated, for removal: This API element is subject to removal in a future version.Creates an instance of aNotification
record class.Notification
(@NotNull Component title, @NotNull FrameType frameType, @NotNull Material icon) Deprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Modifier and TypeMethodDescriptionfinal boolean
Deprecated, for removal: This API element is subject to removal in a future version.Indicates whether some other object is "equal to" this one.@NotNull FrameType
Deprecated, for removal: This API element is subject to removal in a future version.Returns the value of theframeType
record component.final int
hashCode()
Deprecated, for removal: This API element is subject to removal in a future version.Returns a hash code value for this object.@NotNull ItemStack
icon()
Deprecated, for removal: This API element is subject to removal in a future version.Returns the value of theicon
record component.@NotNull Component
title()
Deprecated, for removal: This API element is subject to removal in a future version.Returns the value of thetitle
record component.final String
toString()
Deprecated, for removal: This API element is subject to removal in a future version.Returns a string representation of this record class.
-
Constructor Details
-
Notification
public Notification(@NotNull @NotNull Component title, @NotNull @NotNull FrameType frameType, @NotNull @NotNull Material icon) Deprecated, for removal: This API element is subject to removal in a future version. -
Notification
public Notification(@NotNull @NotNull Component title, @NotNull @NotNull FrameType frameType, @NotNull @NotNull ItemStack icon) Deprecated, for removal: This API element is subject to removal in a future version.Creates an instance of aNotification
record class.- Parameters:
title
- the value for thetitle
record componentframeType
- the value for theframeType
record componenticon
- the value for theicon
record component
-
-
Method Details
-
toString
Deprecated, for removal: This API element is subject to removal in a future version.Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Deprecated, for removal: This API element is subject to removal in a future version.Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Deprecated, for removal: This API element is subject to removal in a future version.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)
. -
title
Deprecated, for removal: This API element is subject to removal in a future version.Returns the value of thetitle
record component.- Returns:
- the value of the
title
record component
-
frameType
Deprecated, for removal: This API element is subject to removal in a future version.Returns the value of theframeType
record component.- Returns:
- the value of the
frameType
record component
-
icon
Deprecated, for removal: This API element is subject to removal in a future version.Returns the value of theicon
record component.- Returns:
- the value of the
icon
record component
-
Notification.builder()
instead.