diff options
Diffstat (limited to 'BJC-Utils2/src/main/java/bjc/utils/funcdata/ExtendedMap.java')
| -rw-r--r-- | BJC-Utils2/src/main/java/bjc/utils/funcdata/ExtendedMap.java | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/BJC-Utils2/src/main/java/bjc/utils/funcdata/ExtendedMap.java b/BJC-Utils2/src/main/java/bjc/utils/funcdata/ExtendedMap.java index 7e6c23b..7db6cea 100644 --- a/BJC-Utils2/src/main/java/bjc/utils/funcdata/ExtendedMap.java +++ b/BJC-Utils2/src/main/java/bjc/utils/funcdata/ExtendedMap.java @@ -1,11 +1,11 @@ package bjc.utils.funcdata; +import bjc.utils.funcutils.ListUtils; + import java.util.function.BiConsumer; import java.util.function.Consumer; import java.util.function.Function; -import bjc.utils.funcutils.ListUtils; - class ExtendedMap<KeyType, ValueType> implements IMap<KeyType, ValueType> { private IMap<KeyType, ValueType> delegate; @@ -23,9 +23,7 @@ class ExtendedMap<KeyType, ValueType> implements IMap<KeyType, ValueType> { @Override public boolean containsKey(KeyType key) { - if (store.containsKey(key)) { - return true; - } + if(store.containsKey(key)) return true; return delegate.containsKey(key); } @@ -58,9 +56,7 @@ class ExtendedMap<KeyType, ValueType> implements IMap<KeyType, ValueType> { @Override public ValueType get(KeyType key) { - if (store.containsKey(key)) { - return store.get(key); - } + if(store.containsKey(key)) return store.get(key); return delegate.get(key); } |
