Class DefaultScheduledTask<V>
- java.lang.Object
-
- de.dytanic.cloudnet.common.concurrent.DefaultScheduledTask<V>
-
- All Implemented Interfaces:
IScheduledTask<V>,ITask<V>,java.util.concurrent.Callable<V>,java.util.concurrent.Future<V>
@Deprecated @ScheduledForRemoval public final class DefaultScheduledTask<V> extends java.lang.Object implements IScheduledTask<V>
Deprecated.
-
-
Constructor Summary
Constructors Constructor Description DefaultScheduledTask(java.util.concurrent.Callable<V> callable, long delay, long repeat, long repeats, java.util.concurrent.TimeUnit timeUnit)Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description @NotNull ITask<V>addListener(ITaskListener<V> listener)Deprecated.Vcall()Deprecated.IScheduledTask<V>cancel()Deprecated.booleancancel(boolean mayInterruptIfRunning)Deprecated.@NotNull ITask<V>clearListeners()Deprecated.Vget()Deprecated.Vget(long timeout, @NotNull java.util.concurrent.TimeUnit unit)Deprecated.Vget(long time, java.util.concurrent.TimeUnit timeUnit, V def)Deprecated.java.util.concurrent.Callable<V>getCallable()Deprecated.VgetDef(V def)Deprecated.longgetDelay()Deprecated.longgetDelayedTimeStamp()Deprecated.longgetDelayMillis()Deprecated.java.util.Collection<ITaskListener<V>>getListeners()Deprecated.longgetRepeat()Deprecated.longgetRepeatMillis()Deprecated.longgetRepeats()Deprecated.longgetTaskId()Deprecated.VgetValue()Deprecated.booleanisCancelled()Deprecated.booleanisDone()Deprecated.booleanisRepeatable()Deprecated.booleanisWait()Deprecated.<T> ITask<T>mapThrowable(ThrowableFunction<V,T,java.lang.Throwable> mapper)Deprecated.voidsetCancelled(boolean cancelled)Deprecated.IScheduledTask<V>setDelayMillis(long delayMillis)Deprecated.voidsetDone(boolean done)Deprecated.IScheduledTask<V>setRepeatMillis(long repeatMillis)Deprecated.voidsetWait(boolean wait)Deprecated.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.dytanic.cloudnet.common.concurrent.ITask
addListener, fireExceptionOnFailure, map, onCancelled, onComplete, onComplete, onFailure, onFailure
-
-
-
-
Constructor Detail
-
DefaultScheduledTask
public DefaultScheduledTask(java.util.concurrent.Callable<V> callable, long delay, long repeat, long repeats, java.util.concurrent.TimeUnit timeUnit)
Deprecated.
-
-
Method Detail
-
addListener
@NotNull public final @NotNull ITask<V> addListener(ITaskListener<V> listener)
Deprecated.- Specified by:
addListenerin interfaceITask<V>
-
getTaskId
public long getTaskId()
Deprecated.- Specified by:
getTaskIdin interfaceIScheduledTask<V>
-
getListeners
public java.util.Collection<ITaskListener<V>> getListeners()
Deprecated.- Specified by:
getListenersin interfaceITask<V>
-
getValue
public V getValue()
Deprecated.
-
isWait
public boolean isWait()
Deprecated.
-
setWait
public void setWait(boolean wait)
Deprecated.
-
isDone
public boolean isDone()
Deprecated.- Specified by:
isDonein interfacejava.util.concurrent.Future<V>
-
setDone
public void setDone(boolean done)
Deprecated.
-
isCancelled
public boolean isCancelled()
Deprecated.- Specified by:
isCancelledin interfacejava.util.concurrent.Future<V>
-
setCancelled
public void setCancelled(boolean cancelled)
Deprecated.
-
getDelay
public long getDelay()
Deprecated.
-
getRepeat
public long getRepeat()
Deprecated.
-
getRepeats
public long getRepeats()
Deprecated.
-
getDelayedTimeStamp
public long getDelayedTimeStamp()
Deprecated.- Specified by:
getDelayedTimeStampin interfaceIScheduledTask<V>
-
getCallable
public java.util.concurrent.Callable<V> getCallable()
Deprecated.- Specified by:
getCallablein interfaceITask<V>
-
clearListeners
@NotNull public @NotNull ITask<V> clearListeners()
Deprecated.- Specified by:
clearListenersin interfaceITask<V>
-
mapThrowable
public <T> ITask<T> mapThrowable(ThrowableFunction<V,T,java.lang.Throwable> mapper)
Deprecated.- Specified by:
mapThrowablein interfaceITask<V>
-
cancel
public boolean cancel(boolean mayInterruptIfRunning)
Deprecated.- Specified by:
cancelin interfacejava.util.concurrent.Future<V>
-
get
public V get() throws java.lang.InterruptedException
Deprecated.- Specified by:
getin interfacejava.util.concurrent.Future<V>- Throws:
java.lang.InterruptedException
-
get
public V get(long timeout, @NotNull @NotNull java.util.concurrent.TimeUnit unit) throws java.lang.InterruptedException
Deprecated.- Specified by:
getin interfacejava.util.concurrent.Future<V>- Throws:
java.lang.InterruptedException
-
isRepeatable
public boolean isRepeatable()
Deprecated.- Specified by:
isRepeatablein interfaceIScheduledTask<V>
-
setDelayMillis
public IScheduledTask<V> setDelayMillis(long delayMillis)
Deprecated.- Specified by:
setDelayMillisin interfaceIScheduledTask<V>
-
getDelayMillis
public long getDelayMillis()
Deprecated.- Specified by:
getDelayMillisin interfaceIScheduledTask<V>
-
setRepeatMillis
public IScheduledTask<V> setRepeatMillis(long repeatMillis)
Deprecated.- Specified by:
setRepeatMillisin interfaceIScheduledTask<V>
-
getRepeatMillis
public long getRepeatMillis()
Deprecated.- Specified by:
getRepeatMillisin interfaceIScheduledTask<V>
-
cancel
public IScheduledTask<V> cancel()
Deprecated.- Specified by:
cancelin interfaceIScheduledTask<V>
-
-