Commit 6066a9e1 authored by mey's avatar mey
Browse files

MapChangeNotifier.java: added method getDefault to UpdateMode

BasicMapChangeNotifier.java
    uses getDefault method to get the default update mode
parent 1275160f
......@@ -21,7 +21,7 @@ class BasicMapChangeNotifier implements MapChangeNotifier, Serializable {
private static final int LISTENERS_INITIAL_CAPACITY = 1;
private final Collection<DynamicMap> dynamicMaps = new ArrayList<>(LISTENERS_INITIAL_CAPACITY);
private UpdateMode updateMode = UpdateMode.LAZY;
private UpdateMode updateMode = UpdateMode.getDefault();
@Override
public final void addListener(DynamicMap listener) {
......
......@@ -46,7 +46,16 @@ public interface MapChangeNotifier {
* Changes are immediately propagated when they happen. Update of
* listeners is done immediately.
*/
EAGER
EAGER;
/**
* Returns the default update mode.
*
* @return the default mode
*/
public static UpdateMode getDefault() {
return LAZY;
}
}
}
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment