public interface SimpleMap<T> extends MapWriter
CharSequence
objects, The values can be of any typeMapWriter.EntryWriter
Modifier and Type | Method and Description |
---|---|
default void |
abortableForEach(BiFunction<String,? super T,Boolean> fun)
Navigate through all key-values but abort in between if required.
|
default void |
abortableForEachKey(Function<String,Boolean> fun)
iterate through all keys but abort in between if required
The default impl is suboptimal.
|
void |
forEachEntry(BiConsumer<String,? super T> fun)
Navigate through all keys and values
|
default void |
forEachKey(Consumer<String> fun)
iterate through all keys
The default impl is suboptimal.
|
T |
get(String key)
get a value by key.
|
int |
size() |
default void |
writeMap(MapWriter.EntryWriter ew) |
_forEachEntry, _forEachEntry, _forEachEntry, _get, _get, _getStr, _getStr, _size
void forEachEntry(BiConsumer<String,? super T> fun)
default void forEachKey(Consumer<String> fun)
int size()
default void abortableForEachKey(Function<String,Boolean> fun)
fun
- Consume each key and return a boolean to signal whether to proceed or not. If true , continue. If false stopdefault void abortableForEach(BiFunction<String,? super T,Boolean> fun)
fun
- Consume each entry and return a boolean to signal whether to proceed or not. If true, continue, if false stopdefault void writeMap(MapWriter.EntryWriter ew) throws IOException
writeMap
in interface MapWriter
IOException
Copyright © 2000-2020 Apache Software Foundation. All Rights Reserved.