public final class MessageNotifier extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
private static class |
MessageNotifier.Worker |
Modifier and Type | Field and Description |
---|---|
private static java.util.concurrent.ScheduledExecutorService |
EXECUTOR |
static IntegerProperty |
PROP_INTERVAL
Property defining the update interval in minutes
|
static BooleanProperty |
PROP_NOTIFIER_ENABLED
Property defining if this task is enabled or not
|
private static java.util.concurrent.ScheduledFuture<?> |
task |
private static java.lang.Runnable |
WORKER |
Modifier | Constructor and Description |
---|---|
private |
MessageNotifier() |
Modifier and Type | Method and Description |
---|---|
static boolean |
isRunning()
Determines if the message notifier is currently running
|
static boolean |
isUserEnoughIdentified()
Determines if user set enough information in JOSM preferences to make the request to OSM API without
prompting him for a password.
|
static void |
start()
Starts the message notifier task if not already started and if user is fully identified
|
static void |
stop()
Stops the message notifier task if started
|
public static final BooleanProperty PROP_NOTIFIER_ENABLED
public static final IntegerProperty PROP_INTERVAL
private static final java.util.concurrent.ScheduledExecutorService EXECUTOR
private static final java.lang.Runnable WORKER
private static java.util.concurrent.ScheduledFuture<?> task
private MessageNotifier()
public static void start()
public static void stop()
public static boolean isRunning()
true
if the notifier is running, false
otherwisepublic static boolean isUserEnoughIdentified()
true
if user chose an OAuth token or supplied both its username and password, false otherwise