Skip to content

Commit dfd9f7f

Browse files
committed
minor wording amendments
1 parent df560b8 commit dfd9f7f

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

src/main/java/org/apache/commons/collections4/MultiMapUtils.java

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -178,18 +178,18 @@ public static boolean isEmpty(final MultiValuedMap<?, ?> map) {
178178
* {@link MultiValuedMap#inverted()}.
179179
*
180180
* @param source take key-to-value mappings from here
181-
* @param dest add value-to-key mappings here
182-
* @param <K> the dest key type
183-
* @param <V> the dest value type
184-
* @param <M> the dest multimap
185-
* @return the destination
181+
* @param collector add value-to-key mappings here
182+
* @param <K> the collector key type
183+
* @param <V> the collector value type
184+
* @param <M> the collector multimap
185+
* @return the updated collector
186186
*/
187187
public static <K, V, M extends MultiValuedMap<K, V>>
188-
M invertInto(MultiValuedMap<? extends V, ? extends K> source, M dest) {
188+
M invertInto(MultiValuedMap<? extends V, ? extends K> source, M collector) {
189189
for (Map.Entry<? extends V, ? extends K> e : source.entries()) {
190-
dest.put(e.getValue(), e.getKey());
190+
collector.put(e.getValue(), e.getKey());
191191
}
192-
return dest;
192+
return collector;
193193
}
194194

195195
/**

src/main/java/org/apache/commons/collections4/MultiValuedMap.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -141,11 +141,11 @@ public interface MultiValuedMap<K, V> {
141141
Collection<V> get(K key);
142142

143143
/**
144-
* Returns the inverse MultiValuedMap with inverted mappings.
144+
* Returns a new MultiValuedMap with inverted mappings.
145145
* The new multimap will have a value-to-key mapping
146146
* for each key-to-value mapping in the original.
147147
*
148-
* @return the inverse MultiValuedMap
148+
* @return a new MultiValuedMap with inverted mappings
149149
*/
150150
default MultiValuedMap<V, K> inverted() {
151151
throw new UnsupportedOperationException();

0 commit comments

Comments
 (0)