Top Fields Constructors Methods
org.eclipse.collections.impl.map.fixed

pack-priv final Class TripletonMap<K, V>

extends AbstractMemoryEfficientMutableMap<K, V>
implements Externalizable
Class Inheritance
All Implemented Interfaces
java.io.Externalizable, java.io.Serializable
Imports
java.io.Externalizable, .IOException, .ObjectInput, .ObjectOutput, java.util.Collection, .Map, .Objects, .Set, org.eclipse.collections.api.block.function.Function2, org.eclipse.collections.api.block.predicate.Predicate2, org.eclipse.collections.api.block.procedure.Procedure, .Procedure2, org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure, org.eclipse.collections.api.factory.Lists, .Maps, .Sets, org.eclipse.collections.api.map.FixedSizeMap, .ImmutableMap, .MutableMap, org.eclipse.collections.api.set.MutableSet, org.eclipse.collections.api.tuple.Pair, org.eclipse.collections.impl.block.factory.Predicates2, org.eclipse.collections.impl.map.mutable.UnifiedMap, org.eclipse.collections.impl.tuple.ImmutableEntry, .Tuples

Field Summary

Modifier and TypeField and Description
private K
private K
private K
private static final long
private V
private V
private V

Constructor Summary

AccessConstructor and Description
public
pack-priv
TripletonMap(K key1, V value1, K key2, V value2, K key3, V value3)

Method Summary

Modifier and TypeMethod and Description
public TripletonMap<K, V>
clone()

Implements abstract org.eclipse.collections.impl.map.mutable.AbstractMutableMap.clone.

Implements org.eclipse.collections.api.map.MutableMap.clone.

Creates and returns a copy of this object.

public <K2, V2> FixedSizeMap<K2, V2>
public <R> FixedSizeMap<R, V>
public <R> FixedSizeMap<K, R>
public boolean
containsKey(Object key)

Implements org.eclipse.collections.api.map.MapIterable.containsKey, java.util.Map.containsKey.

Returns true if this map contains a mapping for the specified key.

public boolean
containsValue(Object value)

Implements org.eclipse.collections.api.map.MapIterable.containsValue, java.util.Map.containsValue.

Returns true if this map maps one or more keys to the specified value.

public Pair<K, V>
detect(Predicate2<? super K, ? super V> predicate)

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMapIterable.detect.

Implements org.eclipse.collections.api.map.MapIterable.detect.

Return the first key and value of the map for which the predicate evaluates to true when they are given as arguments.

public MutableSet<Map.Entry<K, V>>
entrySet()

Implements java.util.Map.entrySet.

Returns a Set view of the mappings contained in this map.

public boolean
private FixedSizeMap<K, V>
filter(Predicate2<? super K, ? super V> predicate)

public MutableMap<V, K>
public void
forEachKey(Procedure<? super K> procedure)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachKey.

Implements org.eclipse.collections.api.map.MapIterable.forEachKey.

Calls the procedure with each key of the map.

public void
forEachKeyValue(Procedure2<? super K, ? super V> procedure)

Implements org.eclipse.collections.api.map.MapIterable.forEachKeyValue.

Calls the procedure with each key-value pair of the map.

public void
forEachValue(Procedure<? super V> procedure)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachValue.

Implements org.eclipse.collections.api.map.MapIterable.forEachValue.

Calls the procedure with each value of the map.

public <P> void
forEachWith(Procedure2<? super V, ? super P> procedure, P parameter)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachWith.

Implements org.eclipse.collections.api.InternalIterable.forEachWith.

The procedure2 is evaluated for each element in the iterable with the specified parameter provided as the second argument.

public void
forEachWithIndex(ObjectIntProcedure<? super V> objectIntProcedure)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachWithIndex.

Implements org.eclipse.collections.api.InternalIterable.forEachWithIndex.

Iterates over the iterable passing each element and the current relative int index to the specified instance of ObjectIntProcedure.

public V
get(Object key)

Implements org.eclipse.collections.api.map.MapIterable.get, java.util.Map.get.

Returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.

pack-priv K
pack-priv K
pack-priv K
public V
getOnly()

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.getOnly.

Overrides default org.eclipse.collections.api.RichIterable.getOnly.

Returns the element if the iterable has exactly one element.

public int
public Set<K>
keySet()

Implements java.util.Map.keySet.

Returns a Set view of the keys contained in this map.

public void
readExternal(ObjectInput in)

Implements java.io.Externalizable.readExternal.

The object implements the readExternal method to restore its contents by calling the methods of DataInput for primitive types and readObject for objects, strings and arrays.

public FixedSizeMap<K, V>
reject(Predicate2<? super K, ? super V> predicate)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.reject.

Implements org.eclipse.collections.api.map.MutableMap.reject, org.eclipse.collections.api.map.MutableMapIterable.reject, org.eclipse.collections.api.map.MapIterable.reject.

For each key and value of the map the predicate is evaluated, if the result of the evaluation is false, that key and value are returned in a new map.

public FixedSizeMap<K, V>
select(Predicate2<? super K, ? super V> predicate)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.select.

Implements org.eclipse.collections.api.map.MutableMap.select, org.eclipse.collections.api.map.MutableMapIterable.select, org.eclipse.collections.api.map.MapIterable.select.

For each key and value of the map the predicate is evaluated, if the result of the evaluation is true, that key and value are returned in a new map.

public int
size()

Implements org.eclipse.collections.api.RichIterable.size, java.util.Map.size.

Returns the number of key-value mappings in this map.

public ImmutableMap<K, V>
public String
toString()

Overrides org.eclipse.collections.impl.AbstractRichIterable.toString.

Implements org.eclipse.collections.api.map.MapIterable.toString, org.eclipse.collections.api.RichIterable.toString.

Returns a string with the keys and values of this map separated by commas with spaces and enclosed in curly braces.

public Collection<V>
values()

Implements java.util.Map.values.

Returns a Collection view of the values contained in this map.

public MutableMap<K, V>
withKeyValue(K addKey, V addValue)

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMap.withKeyValue.

Implements org.eclipse.collections.api.map.MutableMap.withKeyValue, org.eclipse.collections.api.map.MutableMapIterable.withKeyValue.

This method allows mutable, fixed size, and immutable maps the ability to add elements to their existing elements.

public MutableMap<K, V>
withoutKey(K key)

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMap.withoutKey.

Implements org.eclipse.collections.api.map.MutableMap.withoutKey, org.eclipse.collections.api.map.MutableMapIterable.withoutKey.

This method allows mutable, fixed size, and immutable maps the ability to remove elements from their existing elements.

public void
writeExternal(ObjectOutput out)

Implements java.io.Externalizable.writeExternal.

The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings, and arrays.

Inherited from org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap:
clearcollectKeysAndValuesmergenewEmptynewEmptyputputAllremoveremoveAllKeysremoveIfremoveKeytapupdateValueupdateValueWithwithAllKeyValueArgumentswithAllKeyValueswithoutAllKeys

Field Detail

key1back to summary
private K key1
key2back to summary
private K key2
key3back to summary
private K key3
serialVersionUIDback to summary
private static final long serialVersionUID
value1back to summary
private V value1
value2back to summary
private V value2
value3back to summary
private V value3

Constructor Detail

TripletonMapback to summary
public TripletonMap()
Annotations
@SuppressWarnings:UnusedDeclaration
TripletonMapback to summary
pack-priv TripletonMap(K key1, V value1, K key2, V value2, K key3, V value3)

Method Detail

cloneback to summary
public TripletonMap<K, V> clone()

Implements abstract org.eclipse.collections.impl.map.mutable.AbstractMutableMap.clone.

Implements org.eclipse.collections.api.map.MutableMap.clone.

Doc from java.lang.Object.clone.

Creates and returns a copy of this object. The precise meaning of "copy" may depend on the class of the object. The general intent is that, for any object x, the expression:

x.clone() != x
will be true, and that the expression:
x.clone().getClass() == x.getClass()
will be true, but these are not absolute requirements. While it is typically the case that:
x.clone().equals(x)
will be true, this is not an absolute requirement.

By convention, the returned object should be obtained by calling super.clone. If a class and all of its superclasses (except Object) obey this convention, it will be the case that x.clone().getClass() == x.getClass().

By convention, the object returned by this method should be independent of this object (which is being cloned). To achieve this independence, it may be necessary to modify one or more fields of the object returned by super.clone before returning it. Typically, this means copying any mutable objects that comprise the internal "deep structure" of the object being cloned and replacing the references to these objects with references to the copies. If a class contains only primitive fields or references to immutable objects, then it is usually the case that no fields in the object returned by super.clone need to be modified.

Annotations
@Override
collectback to summary
public <K2, V2> FixedSizeMap<K2, V2> collect(Function2<? super K, ? super V, Pair<K2, V2>> function)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.collect.

Implements org.eclipse.collections.api.map.MutableMap.collect, org.eclipse.collections.api.map.MutableMapIterable.collect, org.eclipse.collections.api.map.MapIterable.collect.

Doc from org.eclipse.collections.api.map.MapIterable.collect.

For each key and value of the map the function is evaluated. The results of these evaluations are returned in a new map. The map returned will use the values projected from the function rather than the original values.

MapIterable<String, String> collected =
    peopleByCity.collect((City city, Person person) -> Pair.of(city.getCountry(), person.getAddress().getCity()));
Annotations
@Override
collectKeysUniqueback to summary
public <R> FixedSizeMap<R, V> collectKeysUnique(Function2<? super K, ? super V, ? extends R> function)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.collectKeysUnique.

Implements org.eclipse.collections.api.map.MutableMap.collectKeysUnique, org.eclipse.collections.api.map.MutableMapIterable.collectKeysUnique, org.eclipse.collections.api.map.MapIterable.collectKeysUnique.

Doc from org.eclipse.collections.api.map.MapIterable.collectKeysUnique.

For each key and value of the map the function is evaluated. The results of these evaluations are returned in a new map. The map returned will use the keys projected from the function rather than the original keys.

Annotations
@Override
collectValuesback to summary
public <R> FixedSizeMap<K, R> collectValues(Function2<? super K, ? super V, ? extends R> function)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.collectValues.

Implements org.eclipse.collections.api.map.MutableMap.collectValues, org.eclipse.collections.api.map.MutableMapIterable.collectValues, org.eclipse.collections.api.map.MapIterable.collectValues.

Doc from org.eclipse.collections.api.map.MapIterable.collectValues.

For each key and value of the map the function is evaluated. The results of these evaluations are returned in a new map. The map returned will use the values projected from the function rather than the original values.

MapIterable<City, String> collected =
    peopleByCity.collectValues((City city, Person person) -> person.getFirstName() + " " + person.getLastName());
Annotations
@Override
containsKeyback to summary
public boolean containsKey(Object key)

Implements org.eclipse.collections.api.map.MapIterable.containsKey, java.util.Map.containsKey.

Doc from java.util.Map.containsKey.

Returns true if this map contains a mapping for the specified key. More formally, returns true if and only if this map contains a mapping for a key k such that Objects.equals(key, k). (There can be at most one such mapping.)

Annotations
@Override
containsValueback to summary
public boolean containsValue(Object value)

Implements org.eclipse.collections.api.map.MapIterable.containsValue, java.util.Map.containsValue.

Doc from java.util.Map.containsValue.

Returns true if this map maps one or more keys to the specified value. More formally, returns true if and only if this map contains at least one mapping to a value v such that Objects.equals(value, v). This operation will probably require time linear in the map size for most implementations of the Map interface.

Annotations
@Override
detectback to summary
public Pair<K, V> detect(Predicate2<? super K, ? super V> predicate)

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMapIterable.detect.

Implements org.eclipse.collections.api.map.MapIterable.detect.

Doc from org.eclipse.collections.api.map.MapIterable.detect.

Return the first key and value of the map for which the predicate evaluates to true when they are given as arguments. The predicate will only be evaluated until such pair is found or until all the keys and values of the map have been used as arguments. That is, there may be keys and values of the map that are never used as arguments to the predicate. The result is null if predicate does not evaluate to true for any key/value combination.

Pair<City, Person> detected =
    peopleByCity.detect((City city, Person person) -> city.getName().equals("Anytown") && person.getLastName().equals("Smith"));
Annotations
@Override
entrySetback to summary
public MutableSet<Map.Entry<K, V>> entrySet()

Implements java.util.Map.entrySet.

Doc from java.util.Map.entrySet.

Returns a Set view of the mappings contained in this map. The set is backed by the map, so changes to the map are reflected in the set, and vice-versa. If the map is modified while an iteration over the set is in progress (except through the iterator's own remove operation, or through the setValue operation on a map entry returned by the iterator) the results of the iteration are undefined. The set supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Set.remove, removeAll, retainAll and clear operations. It does not support the add or addAll operations.

Annotations
@Override
equalsback to summary
public boolean equals(Object other)

Overrides java.lang.Object.equals.

Implements org.eclipse.collections.api.map.MapIterable.equals, java.util.Map.equals.

Doc from org.eclipse.collections.api.map.MapIterable.equals.

Follows the same general contract as Map#equals(Object).

Annotations
@Override
filterback to summary
private FixedSizeMap<K, V> filter(Predicate2<? super K, ? super V> predicate)
flipUniqueValuesback to summary
public MutableMap<V, K> flipUniqueValues()

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMapIterable.flipUniqueValues.

Implements org.eclipse.collections.api.map.MutableMap.flipUniqueValues, org.eclipse.collections.api.map.MutableMapIterable.flipUniqueValues, org.eclipse.collections.api.map.MapIterable.flipUniqueValues.

Doc from org.eclipse.collections.api.map.MapIterable.flipUniqueValues.

Return the MapIterable that is obtained by flipping the direction of this map and making the associations from value to key.

    MapIterable<Integer, String> map = this.newMapWithKeysValues(1, "1", 2, "2", 3, "3");
    MapIterable<String, Integer> result = map.flipUniqueValues();
    Assert.assertTrue(result.equals(UnifiedMap.newWithKeysValues("1", 1, "2", 2, "3", 3)));
Annotations
@Override
forEachKeyback to summary
public void forEachKey(Procedure<? super K> procedure)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachKey.

Implements org.eclipse.collections.api.map.MapIterable.forEachKey.

Doc from org.eclipse.collections.api.map.MapIterable.forEachKey.

Calls the procedure with each key of the map.

    final Collection<Integer> result = new ArrayList<Integer>();
    MutableMap<Integer, String> map = this.newMapWithKeysValues(1, "1", 2, "2", 3, "3");
    map.forEachKey(new CollectionAddProcedure<Integer>(result));
    Verify.assertContainsAll(result, 1, 2, 3);
Annotations
@Override
forEachKeyValueback to summary
public void forEachKeyValue(Procedure2<? super K, ? super V> procedure)

Implements org.eclipse.collections.api.map.MapIterable.forEachKeyValue.

Doc from org.eclipse.collections.api.map.MapIterable.forEachKeyValue.

Calls the procedure with each key-value pair of the map.

    final Collection<String> collection = new ArrayList<String>();
    MutableMap<Integer, String> map = this.newMapWithKeysValues(1, "One", 2, "Two", 3, "Three");
    map.forEachKeyValue((Integer key, String value) -> collection.add(String.valueOf(key) + value));
    Verify.assertContainsAll(collection, "1One", "2Two", "3Three");
Annotations
@Override
forEachValueback to summary
public void forEachValue(Procedure<? super V> procedure)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachValue.

Implements org.eclipse.collections.api.map.MapIterable.forEachValue.

Doc from org.eclipse.collections.api.map.MapIterable.forEachValue.

Calls the procedure with each value of the map.

    Set<String> result = UnifiedSet.newSet();
    MutableMap<Integer, String> map = this.newMapWithKeysValues(1, "One", 2, "Two", 3, "Three", 4, "Four");
    map.forEachValue(new CollectionAddProcedure<String>(result));
    Verify.assertSetsEqual(UnifiedSet.newSetWith("One", "Two", "Three", "Four"), result);
Annotations
@Override
forEachWithback to summary
public <P> void forEachWith(Procedure2<? super V, ? super P> procedure, P parameter)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachWith.

Implements org.eclipse.collections.api.InternalIterable.forEachWith.

Doc from org.eclipse.collections.api.InternalIterable.forEachWith.

The procedure2 is evaluated for each element in the iterable with the specified parameter provided as the second argument.

Example using a Java 8 lambda:

people.forEachWith((Person person, Person other) ->
    {
        if (person.isRelatedTo(other))
        {
             LOGGER.info(person.getName());
        }
    }, fred);

Example using an anonymous inner class:

people.forEachWith(new Procedure2<Person, Person>()
{
    public void value(Person person, Person other)
    {
        if (person.isRelatedTo(other))
        {
             LOGGER.info(person.getName());
        }
    }
}, fred);
Annotations
@Override
forEachWithIndexback to summary
public void forEachWithIndex(ObjectIntProcedure<? super V> objectIntProcedure)

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.forEachWithIndex.

Implements org.eclipse.collections.api.InternalIterable.forEachWithIndex.

Doc from org.eclipse.collections.api.InternalIterable.forEachWithIndex.

Iterates over the iterable passing each element and the current relative int index to the specified instance of ObjectIntProcedure.

Example using a Java 8 lambda:

people.forEachWithIndex((Person person, int index) -> LOGGER.info("Index: " + index + " person: " + person.getName()));

Example using an anonymous inner class:

people.forEachWithIndex(new ObjectIntProcedure<Person>()
{
    public void value(Person person, int index)
    {
        LOGGER.info("Index: " + index + " person: " + person.getName());
    }
});
Annotations
@Override
getback to summary
public V get(Object key)

Implements org.eclipse.collections.api.map.MapIterable.get, java.util.Map.get.

Doc from java.util.Map.get.

Returns the value to which the specified key is mapped, or null if this map contains no mapping for the key.

More formally, if this map contains a mapping from a key k to a value v such that Objects.equals(key, k), then this method returns v; otherwise it returns null. (There can be at most one such mapping.)

If this map permits null values, then a return value of null does not necessarily indicate that the map contains no mapping for the key; it's also possible that the map explicitly maps the key to null. The containsKey operation may be used to distinguish these two cases.

Annotations
@Override
getKey1back to summary
pack-priv K getKey1()
getKey2back to summary
pack-priv K getKey2()
getKey3back to summary
pack-priv K getKey3()
getOnlyback to summary
public V getOnly()

Overrides org.eclipse.collections.impl.map.AbstractMapIterable.getOnly.

Overrides default org.eclipse.collections.api.RichIterable.getOnly.

Doc from org.eclipse.collections.api.RichIterable.getOnly.

Returns the element if the iterable has exactly one element. Otherwise, throw IllegalStateException.

Annotations
@Override
hashCodeback to summary
public int hashCode()

Overrides java.lang.Object.hashCode.

Implements org.eclipse.collections.api.map.MapIterable.hashCode, java.util.Map.hashCode.

Doc from org.eclipse.collections.api.map.MapIterable.hashCode.

Follows the same general contract as Map#hashCode().

Annotations
@Override
keySetback to summary
public Set<K> keySet()

Implements java.util.Map.keySet.

Doc from java.util.Map.keySet.

Returns a Set view of the keys contained in this map. The set is backed by the map, so changes to the map are reflected in the set, and vice-versa. If the map is modified while an iteration over the set is in progress (except through the iterator's own remove operation), the results of the iteration are undefined. The set supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Set.remove, removeAll, retainAll, and clear operations. It does not support the add or addAll operations.

Annotations
@Override
readExternalback to summary
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException

Implements java.io.Externalizable.readExternal.

Doc from java.io.Externalizable.readExternal.

The object implements the readExternal method to restore its contents by calling the methods of DataInput for primitive types and readObject for objects, strings and arrays. The readExternal method must read the values in the same sequence and with the same types as were written by writeExternal.

Annotations
@Override
Exceptions
IOException:
if I/O errors occur
ClassNotFoundException:
If the class for an object being restored cannot be found.
rejectback to summary
public FixedSizeMap<K, V> reject(Predicate2<? super K, ? super V> predicate)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.reject.

Implements org.eclipse.collections.api.map.MutableMap.reject, org.eclipse.collections.api.map.MutableMapIterable.reject, org.eclipse.collections.api.map.MapIterable.reject.

Doc from org.eclipse.collections.api.map.MapIterable.reject.

For each key and value of the map the predicate is evaluated, if the result of the evaluation is false, that key and value are returned in a new map.

MapIterable<City, Person> rejected =
    peopleByCity.reject((city, person) -> city.getName().equals("Anytown") && person.getLastName().equals("Smith"));
Annotations
@Override
selectback to summary
public FixedSizeMap<K, V> select(Predicate2<? super K, ? super V> predicate)

Implements abstract org.eclipse.collections.impl.map.fixed.AbstractMemoryEfficientMutableMap.select.

Implements org.eclipse.collections.api.map.MutableMap.select, org.eclipse.collections.api.map.MutableMapIterable.select, org.eclipse.collections.api.map.MapIterable.select.

Doc from org.eclipse.collections.api.map.MapIterable.select.

For each key and value of the map the predicate is evaluated, if the result of the evaluation is true, that key and value are returned in a new map.

MapIterable<City, Person> selected =
    peopleByCity.select((city, person) -> city.getName().equals("Anytown") && person.getLastName().equals("Smith"));
Annotations
@Override
sizeback to summary
public int size()

Implements org.eclipse.collections.api.RichIterable.size, java.util.Map.size.

Doc from java.util.Map.size.

Returns the number of key-value mappings in this map. If the map contains more than Integer.MAX_VALUE elements, returns Integer.MAX_VALUE.

Annotations
@Override
toImmutableback to summary
public ImmutableMap<K, V> toImmutable()

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMap.toImmutable.

Implements org.eclipse.collections.api.map.MutableMapIterable.toImmutable, org.eclipse.collections.api.map.UnsortedMapIterable.toImmutable, org.eclipse.collections.api.map.MapIterable.toImmutable.

Doc from org.eclipse.collections.api.map.MutableMapIterable.toImmutable.

Returns an immutable copy of this map. If the map is immutable, it returns itself.

Annotations
@Override
toStringback to summary
public String toString()

Overrides org.eclipse.collections.impl.AbstractRichIterable.toString.

Implements org.eclipse.collections.api.map.MapIterable.toString, org.eclipse.collections.api.RichIterable.toString.

Doc from org.eclipse.collections.api.map.MapIterable.toString.

Returns a string with the keys and values of this map separated by commas with spaces and enclosed in curly braces. Each key and value is separated by an equals sign.

Assert.assertEquals("{1=1, 2=2, 3=3}", Maps.mutable.with(1, 1, 2, 2, 3, 3).toString());
Annotations
@Override
valuesback to summary
public Collection<V> values()

Implements java.util.Map.values.

Doc from java.util.Map.values.

Returns a Collection view of the values contained in this map. The collection is backed by the map, so changes to the map are reflected in the collection, and vice-versa. If the map is modified while an iteration over the collection is in progress (except through the iterator's own remove operation), the results of the iteration are undefined. The collection supports element removal, which removes the corresponding mapping from the map, via the Iterator.remove, Collection.remove, removeAll, retainAll and clear operations. It does not support the add or addAll operations.

Annotations
@Override
withKeyValueback to summary
public MutableMap<K, V> withKeyValue(K addKey, V addValue)

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMap.withKeyValue.

Implements org.eclipse.collections.api.map.MutableMap.withKeyValue, org.eclipse.collections.api.map.MutableMapIterable.withKeyValue.

Doc from org.eclipse.collections.api.map.MutableMapIterable.withKeyValue.

This method allows mutable, fixed size, and immutable maps the ability to add elements to their existing elements. In order to support fixed size maps, a new instance of a map would have to be returned including the keys and values of the original plus the additional key and value. In the case of mutable maps, the original map is modified and then returned. In order to use this method properly with mutable and fixed size maps the following approach must be taken:

map = map.withKeyValue("new key", "new value");
In the case of FixedSizeMap, a new instance will be returned by withKeyValue, and any variables that previously referenced the original map will need to be redirected to reference the new instance. In the case of a FastMap or UnifiedMap, you will be replacing the reference to map with map, since FastMap and UnifiedMap will both return "this" after calling put on themselves.
Annotations
@Override
withoutKeyback to summary
public MutableMap<K, V> withoutKey(K key)

Overrides org.eclipse.collections.impl.map.mutable.AbstractMutableMap.withoutKey.

Implements org.eclipse.collections.api.map.MutableMap.withoutKey, org.eclipse.collections.api.map.MutableMapIterable.withoutKey.

Doc from org.eclipse.collections.api.map.MutableMapIterable.withoutKey.

This method allows mutable, fixed size, and immutable maps the ability to remove elements from their existing elements. In order to support fixed size maps, a new instance of a map would have to be returned including the keys and values of the original minus the key and value to be removed. In the case of mutable maps, the original map is modified and then returned. In order to use this method properly with mutable and fixed size maps the following approach must be taken:

map = map.withoutKey("key");
In the case of FixedSizeMap, a new instance will be returned by withoutKey, and any variables that previously referenced the original map will need to be redirected to reference the new instance. In the case of a FastMap or UnifiedMap, you will be replacing the reference to map with map, since FastMap and UnifiedMap will both return "this" after calling remove on themselves.
Annotations
@Override
writeExternalback to summary
public void writeExternal(ObjectOutput out) throws IOException

Implements java.io.Externalizable.writeExternal.

Doc from java.io.Externalizable.writeExternal.

The object implements the writeExternal method to save its contents by calling the methods of DataOutput for its primitive values or calling the writeObject method of ObjectOutput for objects, strings, and arrays.

Annotations
@Override
Exceptions
IOException:
Includes any I/O exceptions that may occur