VCollections – Release 1
Interface org.violetlib.collections.MapListBuilder
Deprecated: ShowHide
-
- All Known Subinterfaces:
- UnorderedMapListBuilder<K,V>
public interface MapListBuilder<K,V>
Build an immutable map from keys of type K to immutable lists of values of type V. Null values are not supported.
-
-
|
Modifier and Type |
Method and Description |
|
add |
abstract void add(K key,
V value)
Add an element at the end of the list associated with the specified key.
-
Add an element at the end of the list associated with the specified key.
- Parameters:
key - The key.value - The value to be added.
|
|
addAll |
abstract void addAll(K key,
IList<V> values)
Add elements at the end of the list associated with the specified key.
void addAll( K key,
IList< V> values)
-
Add elements at the end of the list associated with the specified key.
- Parameters:
key - The key.values - The values to be added.
|
|
getValueCount |
abstract int getValueCount(K key)
Return the number of values associated with the specified key.
-
Return the number of values associated with the specified key.
- Parameters:
key - The key.
- Returns:
- the number of values associated with
key .
|
|
getValues |
abstract IList<V> getValues(K key)
Return the values currently associated with the specified key.
-
Return the values currently associated with the specified key.
- Parameters:
key - The key.
- Returns:
- an immutable list that contains the values associated with the specified key.
|
|
keys |
Return the keys that have associated values.
-
Return the keys that have associated values.
|
|
size |
abstract int size()
Return the number of keys with associated values.
int size()
-
Return the number of keys with associated values.
|
|
value |
Return a map containing the keys bound to lists of values.
-
Return a map containing the keys bound to lists of values.
|