mirror of
https://github.com/essentials/Essentials.git
synced 2025-08-07 07:06:41 +02:00
Update pom.xml for 1.4.7 R1 :: Replace deprecated scheduleAsyncDelayedTask
This commit is contained in:
@@ -23,7 +23,7 @@ public interface IPlugin extends Plugin
|
||||
* @param run - Code to call later
|
||||
* @return - BukkitTask for the task created
|
||||
*/
|
||||
BukkitTask scheduleAsyncDelayedTask(final Runnable run);
|
||||
BukkitTask runTaskAsynchronously(final Runnable run);
|
||||
|
||||
/**
|
||||
* Schedule a sync task (ran in main thread) to be run
|
||||
@@ -40,7 +40,7 @@ public interface IPlugin extends Plugin
|
||||
* @param delay - Long that represents how long to wait
|
||||
* @return - BukkitTask for the task created
|
||||
*/
|
||||
BukkitTask scheduleAsyncDelayedTask(final Runnable run, final long delay);
|
||||
BukkitTask runTaskLaterAsynchronously(final Runnable run, final long delay);
|
||||
|
||||
/**
|
||||
* Schedule a sync (ran in main thread) delayed task
|
||||
|
@@ -76,7 +76,7 @@ public class Backup implements Runnable, IBackup
|
||||
}
|
||||
}
|
||||
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(new BackupRunner(backupCommand));
|
||||
ess.getPlugin().runTaskAsynchronously(new BackupRunner(backupCommand));
|
||||
}
|
||||
|
||||
|
||||
|
@@ -133,7 +133,7 @@ public class BukkitPlugin extends JavaPlugin implements IPlugin
|
||||
}
|
||||
|
||||
@Override
|
||||
public BukkitTask scheduleAsyncDelayedTask(final Runnable run)
|
||||
public BukkitTask runTaskAsynchronously(final Runnable run)
|
||||
{
|
||||
return getServer().getScheduler().runTaskAsynchronously(this, run);
|
||||
}
|
||||
@@ -145,7 +145,7 @@ public class BukkitPlugin extends JavaPlugin implements IPlugin
|
||||
}
|
||||
|
||||
@Override
|
||||
public BukkitTask scheduleAsyncDelayedTask(final Runnable run, final long delay)
|
||||
public BukkitTask runTaskLaterAsynchronously(final Runnable run, final long delay)
|
||||
{
|
||||
return getServer().getScheduler().runTaskLaterAsynchronously(this, run, delay);
|
||||
}
|
||||
|
@@ -84,7 +84,7 @@ public class Commandbalancetop extends EssentialsCommand
|
||||
{
|
||||
lock.readLock().unlock();
|
||||
}
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(new Viewer(sender, page, force));
|
||||
ess.getPlugin().runTaskAsynchronously(new Viewer(sender, page, force));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -92,7 +92,7 @@ public class Commandbalancetop extends EssentialsCommand
|
||||
{
|
||||
sender.sendMessage(_("orderBalances", ess.getUserMap().getUniqueUsers()));
|
||||
}
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(new Viewer(sender, page, force));
|
||||
ess.getPlugin().runTaskAsynchronously(new Viewer(sender, page, force));
|
||||
}
|
||||
|
||||
}
|
||||
@@ -169,7 +169,7 @@ public class Commandbalancetop extends EssentialsCommand
|
||||
{
|
||||
lock.writeLock().unlock();
|
||||
}
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(viewer);
|
||||
ess.getPlugin().runTaskAsynchronously(viewer);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -203,7 +203,7 @@ public class Commandbalancetop extends EssentialsCommand
|
||||
{
|
||||
lock.readLock().unlock();
|
||||
}
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(new Calculator(new Viewer(sender, page, force), force));
|
||||
ess.getPlugin().runTaskAsynchronously(new Calculator(new Viewer(sender, page, force), force));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -56,7 +56,7 @@ public class Commandmail extends EssentialsCommand
|
||||
{
|
||||
throw new Exception(_("noPerm", "essentials.mail.sendall"));
|
||||
}
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(new SendAll(user.getName() + ": " + FormatUtil.stripColor(getFinalArg(args, 1))));
|
||||
ess.getPlugin().runTaskAsynchronously(new SendAll(user.getName() + ": " + FormatUtil.stripColor(getFinalArg(args, 1))));
|
||||
user.sendMessage(_("mailSent"));
|
||||
return;
|
||||
}
|
||||
@@ -90,7 +90,7 @@ public class Commandmail extends EssentialsCommand
|
||||
}
|
||||
else if (args.length >= 1 && "sendall".equalsIgnoreCase(args[0]))
|
||||
{
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(new SendAll("Server: " + getFinalArg(args, 2)));
|
||||
ess.getPlugin().runTaskAsynchronously(new SendAll("Server: " + getFinalArg(args, 2)));
|
||||
}
|
||||
else if (args.length >= 2)
|
||||
{
|
||||
|
@@ -164,7 +164,7 @@ public class EssentialsPlayerListener implements Listener
|
||||
@EventHandler(priority = EventPriority.MONITOR)
|
||||
public void onPlayerJoin(final PlayerJoinEvent event)
|
||||
{
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(
|
||||
ess.getPlugin().runTaskAsynchronously(
|
||||
new Runnable()
|
||||
{
|
||||
@Override
|
||||
|
@@ -37,7 +37,7 @@ public class MetricsListener implements Listener
|
||||
ess.getLogger().log(Level.INFO, _("metrics3"));
|
||||
settings.getData().getGeneral().setMetricsEnabled(true);
|
||||
settings.queueSave();
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(starter, 5 * 1200);
|
||||
ess.getPlugin().runTaskLaterAsynchronously(starter, 5 * 1200);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@@ -28,7 +28,7 @@ public abstract class AbstractDelayedYamlFileReader<T extends StorageObject> imp
|
||||
}
|
||||
else
|
||||
{
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(this);
|
||||
ess.getPlugin().runTaskAsynchronously(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -21,7 +21,7 @@ public abstract class AbstractDelayedYamlFileWriter implements Runnable
|
||||
|
||||
public void schedule()
|
||||
{
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(this);
|
||||
ess.getPlugin().runTaskAsynchronously(this);
|
||||
}
|
||||
|
||||
public abstract File getFile();
|
||||
|
@@ -47,7 +47,7 @@ public abstract class StorageObjectMap<I> extends CacheLoader<String, I> impleme
|
||||
|
||||
private void loadAllObjectsAsync()
|
||||
{
|
||||
ess.getPlugin().scheduleAsyncDelayedTask(
|
||||
ess.getPlugin().runTaskAsynchronously(
|
||||
new Runnable()
|
||||
{
|
||||
@Override
|
||||
|
@@ -44,7 +44,7 @@ public class StorageQueue implements Runnable
|
||||
}
|
||||
else if (state == RequestState.SCHEDULE)
|
||||
{
|
||||
plugin.scheduleAsyncDelayedTask(request.getRunnable());
|
||||
plugin.runTaskAsynchronously(request.getRunnable());
|
||||
}
|
||||
}
|
||||
requests.clear();
|
||||
@@ -74,7 +74,7 @@ public class StorageQueue implements Runnable
|
||||
{
|
||||
synchronized (lock)
|
||||
{
|
||||
plugin.scheduleAsyncDelayedTask(this);
|
||||
plugin.runTaskAsynchronously(this);
|
||||
}
|
||||
}
|
||||
|
||||
|
@@ -90,7 +90,7 @@ public class StateMachine extends AbstractWorkListener implements Runnable
|
||||
public void startWork()
|
||||
{
|
||||
iterator = states.values().iterator();
|
||||
Bukkit.getScheduler().scheduleAsyncDelayedTask(getPlugin(), this); //Should this be async? (method deprecated)
|
||||
Bukkit.getScheduler().runTaskAsynchronously(getPlugin(), this); //Should this be async? (method deprecated)
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -149,7 +149,7 @@ public class StateMachine extends AbstractWorkListener implements Runnable
|
||||
{
|
||||
StateMachine.this.player.sendMessage(message);
|
||||
}
|
||||
Bukkit.getScheduler().scheduleAsyncDelayedTask(getPlugin(), StateMachine.this); //Should this be async? (method deprecated)
|
||||
Bukkit.getScheduler().runTaskAsynchronously(getPlugin(), StateMachine.this); //Should this be async? (method deprecated)
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@@ -31,7 +31,7 @@ public class InstallModule implements Runnable, Task
|
||||
@Override
|
||||
public void start()
|
||||
{
|
||||
Bukkit.getScheduler().scheduleAsyncDelayedTask(listener.getPlugin(), this); //Should this be async? (method deprecated)
|
||||
Bukkit.getScheduler().runTaskAsynchronously(listener.getPlugin(), this); //Should this be async? (method deprecated)
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@@ -44,7 +44,7 @@ public class SelfUpdate extends AbstractWorkListener implements Task, Runnable
|
||||
@Override
|
||||
public void run()
|
||||
{
|
||||
Bukkit.getScheduler().scheduleAsyncDelayedTask( //Should this be async? (method deprecated)
|
||||
Bukkit.getScheduler().runTaskAsynchronously( //Should this be async? (method deprecated)
|
||||
getPlugin(), new Runnable()
|
||||
{
|
||||
@Override
|
||||
|
2
pom.xml
2
pom.xml
@@ -75,7 +75,7 @@
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<bukkit.version>1.4.7-R0.1</bukkit.version>
|
||||
<bukkit.version>1.4.7-R1.0</bukkit.version>
|
||||
<build.number>Unknown</build.number>
|
||||
<org-netbeans-modules-editor-indent.CodeStyle.project.expand-tabs>true</org-netbeans-modules-editor-indent.CodeStyle.project.expand-tabs>
|
||||
<org-netbeans-modules-editor-indent.CodeStyle.project.indent-shift-width>2</org-netbeans-modules-editor-indent.CodeStyle.project.indent-shift-width>
|
||||
|
Reference in New Issue
Block a user