Class QueuedCommand
- java.lang.Object
-
- com.onarandombox.MultiverseCore.commandtools.queue.QueuedCommand
-
public class QueuedCommand extends java.lang.ObjectRepresents a single command used inCommandQueueManagerfor confirming before running potentially dangerous action.
-
-
Constructor Summary
Constructors Constructor Description QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action)QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action, int validDuration)QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action, java.lang.String prompt)QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action, java.lang.String prompt, int validDuration)Creates a new queue command, to be registered atCommandQueueManager.addToQueue(QueuedCommand).
-
-
-
Constructor Detail
-
QueuedCommand
public QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action)
-
QueuedCommand
public QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action, java.lang.String prompt)
-
QueuedCommand
public QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action, int validDuration)
-
QueuedCommand
public QueuedCommand(org.bukkit.command.CommandSender sender, java.lang.Runnable action, java.lang.String prompt, int validDuration)Creates a new queue command, to be registered atCommandQueueManager.addToQueue(QueuedCommand).- Parameters:
sender- The sender that ran the command needed for confirmation.action- The logic to execute upon confirming.prompt- Question to ask sender to confirm.validDuration- Duration in which the command is valid for confirm in seconds.
-
-