Package dev.unnm3d.redischat.mail
Class Mail
java.lang.Object
xyz.xenondevs.invui.item.impl.AbstractItem
dev.unnm3d.redischat.mail.Mail
- All Implemented Interfaces:
xyz.xenondevs.invui.item.Item
public class Mail
extends xyz.xenondevs.invui.item.impl.AbstractItem
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionMail
(@NotNull MailGUIManager manager, double id, String serialized) Creates a mail from a serialized stringMail
(@NotNull MailGUIManager manager, @NotNull String sender, @NotNull String receiver, @NotNull String title) Creates a new mail -
Method Summary
Modifier and TypeMethodDescriptionxyz.xenondevs.invui.item.ItemProvider
void
handleClick
(@NotNull org.bukkit.event.inventory.ClickType clickType, @NotNull org.bukkit.entity.Player player, @NotNull org.bukkit.event.inventory.InventoryClickEvent event) void
openPreview
(@NotNull org.bukkit.entity.Player player, boolean readStatus) Opens the mail preview to the player The most hard part of RedisChatMethods inherited from class xyz.xenondevs.invui.item.impl.AbstractItem
addWindow, getWindows, notifyWindows, removeWindow
-
Constructor Details
-
Mail
public Mail(@NotNull @NotNull MailGUIManager manager, @NotNull @NotNull String sender, @NotNull @NotNull String receiver, @NotNull @NotNull String title) Creates a new mail- Parameters:
sender
- The sender of the mailreceiver
- The mail receivertitle
- The title of the mail
-
Mail
Creates a mail from a serialized string- Parameters:
id
- The mail idserialized
- The serialized mail string
-
-
Method Details
-
serialize
-
serializeWithId
-
getItemProvider
public xyz.xenondevs.invui.item.ItemProvider getItemProvider() -
handleClick
public void handleClick(@NotNull @NotNull org.bukkit.event.inventory.ClickType clickType, @NotNull @NotNull org.bukkit.entity.Player player, @NotNull @NotNull org.bukkit.event.inventory.InventoryClickEvent event) -
openPreview
public void openPreview(@NotNull @NotNull org.bukkit.entity.Player player, boolean readStatus) Opens the mail preview to the player The most hard part of RedisChat- Parameters:
player
- The player to open the preview toreadStatus
- If the mail should be marked as read
-