/** * @since Available in iOS 4.0 and later. */ public static void once(Runnable block) { MachineSizedSIntPtr ptr = new MachineSizedSIntPtr(); once(ptr, block); } /*<methods>*/
/** * @since Available in iOS 4.0 and later. */ public void after(long delay, java.util.concurrent.TimeUnit unit, Runnable block) { after(Dispatch.time(Dispatch.TIME_NOW, unit.toNanos(delay)), this, block); } /**
/** * Submits the specified {@link Runnable} on this {@link DispatchQueue} at * the specified time. * * @param when the time when to submit the {@link Runnable}. * @param block the {@link Runnable} to be run. * * @since Available in iOS 4.0 and later. */ public void at(Date when, Runnable block) { long ms = when.getTime(); timespec ts = new timespec(ms / 1000, (ms % 1000) * 1000); after(Dispatch.walltime(ts, 0), this, block); } /*<methods>*/
/** * @since Available in iOS 4.0 and later. */ public void after(long delay, java.util.concurrent.TimeUnit unit, Runnable block) { after(Dispatch.time(Dispatch.TIME_NOW, unit.toNanos(delay)), this, block); } /**
/** * @since Available in iOS 4.0 and later. */ public static void once(Runnable block) { MachineSizedSIntPtr ptr = new MachineSizedSIntPtr(); once(ptr, block); } /*<methods>*/
/** * Submits the specified {@link Runnable} on this {@link DispatchQueue} at * the specified time. * * @param when the time when to submit the {@link Runnable}. * @param block the {@link Runnable} to be run. * * @since Available in iOS 4.0 and later. */ public void at(Date when, Runnable block) { long ms = when.getTime(); timespec ts = new timespec(ms / 1000, (ms % 1000) * 1000); after(Dispatch.walltime(ts, 0), this, block); } /*<methods>*/
/** * @since Available in iOS 4.0 and later. */ public void after(long delay, java.util.concurrent.TimeUnit unit, Runnable block) { after(Dispatch.time(Dispatch.TIME_NOW, unit.toNanos(delay)), this, block); } /**
/** * @since Available in iOS 4.0 and later. */ public static void once(Runnable block) { MachineSizedSIntPtr ptr = new MachineSizedSIntPtr(); once(ptr, block); } /*<methods>*/
/** * Submits the specified {@link Runnable} on this {@link DispatchQueue} at * the specified time. * * @param when the time when to submit the {@link Runnable}. * @param block the {@link Runnable} to be run. * * @since Available in iOS 4.0 and later. */ public void at(Date when, Runnable block) { long ms = when.getTime(); timespec ts = new timespec(ms / 1000, (ms % 1000) * 1000); after(Dispatch.walltime(ts, 0), this, block); } /*<methods>*/