public static final class ImmutableValueMap.Builder extends Object
ImmutableValueMap.| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
@NotNull ImmutableValueMap |
build()
Returns a newly-created immutable map.
|
@NotNull ImmutableValueMap.Builder |
put(@NotNull Map.Entry<String,Object> entry)
Adds the given
entry to the map, making it immutable if
necessary. |
@NotNull ImmutableValueMap.Builder |
put(@NotNull String key,
@NotNull Object value)
Associates
key with value in the built map. |
@NotNull ImmutableValueMap.Builder |
putAll(@NotNull Map<String,Object> value)
Associates all of the given map's keys and values in the built map.
|
@NotNull public @NotNull ImmutableValueMap.Builder put(@NotNull @NotNull String key, @NotNull @NotNull Object value)
key with value in the built map. Duplicate
keys are not allowed, and will cause build() to fail.key - Keyvalue - value@NotNull public @NotNull ImmutableValueMap.Builder put(@NotNull @NotNull Map.Entry<String,Object> entry)
entry to the map, making it immutable if
necessary. Duplicate keys are not allowed, and will cause build() to fail.entry - Entry@NotNull public @NotNull ImmutableValueMap.Builder putAll(@NotNull @NotNull Map<String,Object> value)
build() to fail.value - ValueNullPointerException - if any key or value in map is null@NotNull public @NotNull ImmutableValueMap build()
IllegalArgumentException - if duplicate keys were addedCopyright © 2014–2019 wcm.io. All rights reserved.