public class Sleep extends Object
| Constructor and Description |
|---|
Sleep() |
| Modifier and Type | Method and Description |
|---|---|
static void |
ignoreInterrupt(@NotNull Duration time)
ignore InterruptedException and wake up
|
static void |
ignoreInterrupt(long ms)
ignore InterruptedException and wake up
|
static void |
snoozeInterrupt(@NotNull Duration time)
ignore InterruptedException and continue to sleep
|
static void |
snoozeInterrupt(long ms)
ignore InterruptedException and continue to sleep
|
static void |
throwsInterrupt(@NotNull Duration time,
boolean keep)
throw IllegalStateException, and set whether to keep interrupt status
|
static void |
throwsInterrupt(long ms,
boolean keep)
throw IllegalStateException, and set whether to keep interrupt status
|
public static void ignoreInterrupt(@NotNull
@NotNull Duration time)
public static void ignoreInterrupt(long ms)
public static void snoozeInterrupt(@NotNull
@NotNull Duration time)
public static void snoozeInterrupt(long ms)
public static void throwsInterrupt(@NotNull
@NotNull Duration time,
boolean keep)
public static void throwsInterrupt(long ms,
boolean keep)
Copyright © 2023. All rights reserved.