| Modifier and Type | Field and Description |
|---|---|
| private final MutableOrderedMap | |
| private static final long |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public <KK, VV> ImmutableOrderedMap | aggregateBy(Function<? super V, ? extends KK> groupBy, Function0<? extends VV> zeroValueFactory, Function2<? super VV, ? super V, ? extends VV> nonMutatingAggregator)
Overrides default org. Implements org. Applies an aggregate function over the iterable grouping results into a map based on the specific groupBy function. |
| public <KK, VVV, VV> ImmutableOrderedMap | aggregateBy(Function<? super K, ? extends KK> keyFunction, Function<? super V, ? extends VVV> valueFunction, Function0<? extends VV> zeroValueFactory, Function2<? super VV, ? super VVV, ? extends VV> nonMutatingAggregator)
Overrides default org. Applies an aggregate function over the map grouping results into a map based on the specific key and value groupBy functions. |
| public <KK, VV> ImmutableOrderedMap | aggregateInPlaceBy(Function<? super V, ? extends KK> groupBy, Function0<? extends VV> zeroValueFactory, Procedure2<? super VV, ? super V> mutatingAggregator)
Overrides default org. Implements org. Applies an aggregate procedure over the iterable grouping results into a Map based on the specific groupBy function. |
| public Map | |
| public void | clear()
Implements java. Removes all of the mappings from this map (optional operation). |
| public <K2, V2> ImmutableOrderedMap | collect(Function2<? super K, ? super V, Pair<K2, V2>> function)
Implements org. For each key and value of the map the function is evaluated. |
| public <VV> ImmutableList | collect(Function<? super V, ? extends VV> function)
Implements org. Returns a new collection with the results of applying the specified function on each element of the source collection. |
| public ImmutableBooleanList | collectBoolean(BooleanFunction<? super V> booleanFunction)
Implements org. Returns a new primitive |
| public ImmutableByteList | collectByte(ByteFunction<? super V> byteFunction)
Implements org. Returns a new primitive |
| public ImmutableCharList | collectChar(CharFunction<? super V> charFunction)
Implements org. Returns a new primitive |
| public ImmutableDoubleList | collectDouble(DoubleFunction<? super V> doubleFunction)
Implements org. Returns a new primitive |
| public ImmutableFloatList | collectFloat(FloatFunction<? super V> floatFunction)
Implements org. Returns a new primitive |
| public <VV> ImmutableList | collectIf(Predicate<? super V> predicate, Function<? super V, ? extends VV> function)
Implements org. Returns a new collection with the results of applying the specified function on each element of the source collection, but only for those elements which return true upon evaluation of the predicate. |
| public ImmutableIntList | collectInt(IntFunction<? super V> intFunction)
Implements org. Returns a new primitive |
| public <R> ImmutableOrderedMap | collectKeysUnique(Function2<? super K, ? super V, ? extends R> function)
Implements org. For each key and value of the map the function is evaluated. |
| public ImmutableLongList | collectLong(LongFunction<? super V> longFunction)
Implements org. Returns a new primitive |
| public ImmutableShortList | collectShort(ShortFunction<? super V> shortFunction)
Implements org. Returns a new primitive |
| public <R> ImmutableOrderedMap | collectValues(Function2<? super K, ? super V, ? extends R> function)
Implements org. For each key and value of the map the function is evaluated. |
| public <P, VV> ImmutableList | collectWith(Function2<? super V, ? super P, ? extends VV> function, P parameter)
Implements org. Same as |
| public boolean | containsKey(Object key)
Implements org. Returns |
| public boolean | containsValue(Object value)
Implements org. Returns |
| public <S> boolean | corresponds(OrderedIterable<S> other, Predicate2<? super V, ? super S> predicate)
Implements org. Returns true if both OrderedIterables have the same length
and |
| public <V1> ImmutableBag | countByEach(Function<? super V, ? extends Iterable<V1>> function)
Overrides org. Overrides default org. This method will count the number of occurrences of each value calculated by applying the function to each element of the collection. |
| public V | detect(Predicate<? super V> predicate)
Overrides org. Implements org. Returns the first element of the iterable for which the predicate evaluates to true or null in the case where no element returns true. |
| public Pair | detect(Predicate2<? super K, ? super V> predicate)
Implements org. Return the first key and value of the map for which the predicate evaluates to true when they are given as arguments. |
| public int | detectIndex(Predicate<? super V> predicate)
Implements org. Returns the index of the first element of the |
| public int | detectLastIndex(Predicate<? super V> predicate)
Implements org. Returns the index of the last element of the |
| public Optional | detectOptional(Predicate<? super V> predicate)
Overrides org. Implements org. Returns the first element of the iterable for which the predicate evaluates to true as an Optional. |
| public Optional | detectOptional(Predicate2<? super K, ? super V> predicate)
Implements org. Return the first key and value of the map as an Optional for which the predicate evaluates to true when they are given as arguments. |
| public ImmutableList | distinct()
Implements org. Returns a new |
| public ImmutableOrderedMap | drop(int count)
Implements org. Returns an iterable after skipping the first |
| public ImmutableOrderedMap | dropWhile(Predicate<? super V> predicate)
Implements org. Returns the final elements that do not satisfy the Predicate. |
| public Set | entrySet()
Implements java. Returns a |
| public boolean | equals(Object obj)
Overrides java. Implements org. Compares the specified object with this map for equality. |
| public <VV> ImmutableList | flatCollect(Function<? super V, ? extends Iterable<VV>> function)
Implements org.
|
| public ImmutableListMultimap | flip()
Implements org. Given a map from Domain |
| public ImmutableOrderedMap | flipUniqueValues()
Implements org. Return the MapIterable that is obtained by flipping the direction of this map and making the associations from value to key. |
| public void | forEach(BiConsumer<? super K, ? super V> action)
Overrides default org. Performs the given action for each entry in this map until all entries have been processed or the action throws an exception. |
| public void | forEach(int startIndex, int endIndex, Procedure<? super V> procedure)
Implements org. Iterates over the section of the iterable covered by the specified inclusive indexes. |
| public void | forEachKey(Procedure<? super K> procedure)
Overrides org. Implements org. Calls the |
| public void | forEachKeyValue(Procedure2<? super K, ? super V> procedure)
Implements org. Calls the |
| public void | forEachValue(Procedure<? super V> procedure)
Overrides org. Implements org. Calls the procedure with each value of the map. |
| public <P> void | forEachWith(Procedure2<? super V, ? super P> procedure, P parameter)
Overrides org. Implements org. 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. Implements org. Iterates over the iterable passing each element and the current relative int index to the specified instance of ObjectIntProcedure. |
| public void | forEachWithIndex(int fromIndex, int toIndex, ObjectIntProcedure<? super V> objectIntProcedure)
Implements org. Iterates over the section of the iterable covered by the specified inclusive indexes. |
| public V | get(Object key)
Implements org. Returns the value to which the specified key is mapped,
or |
| public V | getIfAbsent(K key, Function0<? extends V> function)
Overrides org. Implements org. Return the value in the Map that corresponds to the specified key, or if there is no value at the key, return the result of evaluating the specified Function0. |
| public V | getIfAbsentValue(K key, V value)
Overrides org. Implements org. Return the value in the Map that corresponds to the specified key, or if there is no value at the key, return |
| public <P> V | getIfAbsentWith(K key, Function<? super P, ? extends V> function, P parameter)
Overrides org. Implements org. Return the value in the Map that corresponds to the specified key, or if there is no value at the key, return the result of evaluating the specified function and parameter. |
| public <VV> ImmutableListMultimap | groupBy(Function<? super V, ? extends VV> function)
Implements org. For each element of the iterable, the function is evaluated and the results of these evaluations are collected into a new multimap, where the transformed value is the key and the original values are added to the same (or similar) species of collection as the source iterable. |
| public <VV> ImmutableListMultimap | groupByEach(Function<? super V, ? extends Iterable<VV>> function)
Implements org. Similar to |
| public <VV> ImmutableOrderedMap | groupByUniqueKey(Function<? super V, ? extends VV> function)
Implements org. For each element of the iterable, the function is evaluated, and the results of these evaluations are collected into a new map, where the transformed value is the key. |
| public int | hashCode()
Overrides java. Implements org. Returns the hash code value for this map. |
| public <A> A | ifPresentApply(K key, Function<? super V, ? extends A> function)
Overrides org. Implements org. If there is a value in the Map that corresponds to the specified key return the result of applying the specified Function on the value, otherwise return null. |
| public Iterator | |
| public Set | |
| public RichIterable | keysView()
Implements org. Returns an unmodifiable lazy iterable wrapped around the keySet for the map. |
| public RichIterable | keyValuesView()
Implements org. Returns an unmodifiable lazy iterable of key/value pairs wrapped around the entrySet for the map. |
| public ImmutableOrderedMap | newWithAllKeyValueArguments(Pair<? extends K, ? extends V>... keyValuePairs)
Implements org.
|
| public ImmutableOrderedMap | newWithAllKeyValues(Iterable<? extends Pair<? extends K, ? extends V>> keyValues)
Implements org.
|
| public ImmutableOrderedMap | newWithKeyValue(K key, V value)
Implements org.
|
| public ImmutableOrderedMap | newWithMap(Map<? extends K, ? extends V> map)
Implements org.
|
| public ImmutableOrderedMap | newWithMapIterable(MapIterable<? extends K, ? extends V> mapIterable)
Implements org.
|
| public ImmutableOrderedMap | newWithoutAllKeys(Iterable<? extends K> keys)
Implements org.
|
| public ImmutableOrderedMap | |
| public PartitionImmutableList | partition(Predicate<? super V> predicate)
Implements org. Filters a collection into a PartitionedIterable based on the evaluation of the predicate. |
| public PartitionImmutableList | partitionWhile(Predicate<? super V> predicate)
Implements org. Returns a Partition of the initial elements that satisfy the Predicate and the remaining elements. |
| public <P> PartitionImmutableList | partitionWith(Predicate2<? super V, ? super P> predicate, P parameter)
Implements org. Filters a collection into a PartitionIterable based on the evaluation of the predicate. |
| public V | put(K key, V value)
Implements java. Associates the specified value with the specified key in this map (optional operation). |
| public void | putAll(Map<? extends K, ? extends V> map)
Implements java. Copies all of the mappings from the specified map to this map (optional operation). |
| public <KK> ImmutableOrderedMap | reduceBy(Function<? super V, ? extends KK> groupBy, Function2<? super V, ? super V, ? extends V> reduceFunction)
Overrides default org. Implements org. Applies an aggregate function over the iterable grouping results into a map based on the specific groupBy function. |
| public ImmutableOrderedMap | reject(Predicate2<? super K, ? super V> predicate)
Implements org. 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 ImmutableList | reject(Predicate<? super V> predicate)
Implements org. Returns all elements of the source collection that return false when evaluating of the predicate. |
| public <P> ImmutableList | rejectWith(Predicate2<? super V, ? super P> predicate, P parameter)
Implements org. Similar to |
| public V | remove(Object key)
Implements java. Removes the mapping for a key from this map if it is present (optional operation). |
| public ImmutableOrderedMap | select(Predicate2<? super K, ? super V> predicate)
Implements org. 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 ImmutableList | select(Predicate<? super V> predicate)
Implements org. Returns all elements of the source collection that return true when evaluating the predicate. |
| public <S> ImmutableList | selectInstancesOf(Class<S> clazz)
Implements org. Returns all elements of the source collection that are instances of the Class |
| public <P> ImmutableList | selectWith(Predicate2<? super V, ? super P> predicate, P parameter)
Implements org. Similar to |
| public int | size()
Implements org. Returns the number of key-value mappings in this map. |
| public <VV> ImmutableObjectDoubleMap | sumByDouble(Function<? super V, ? extends VV> groupBy, DoubleFunction<? super V> function)
Implements org. Groups and sums the values using the two specified functions. |
| public <VV> ImmutableObjectDoubleMap | sumByFloat(Function<? super V, ? extends VV> groupBy, FloatFunction<? super V> function)
Implements org. Groups and sums the values using the two specified functions. |
| public <VV> ImmutableObjectLongMap | sumByInt(Function<? super V, ? extends VV> groupBy, IntFunction<? super V> function)
Implements org. Groups and sums the values using the two specified functions. |
| public <VV> ImmutableObjectLongMap | sumByLong(Function<? super V, ? extends VV> groupBy, LongFunction<? super V> function)
Implements org. Groups and sums the values using the two specified functions. |
| public ImmutableOrderedMap | take(int count)
Implements org. Returns the first |
| public ImmutableOrderedMap | takeWhile(Predicate<? super V> predicate)
Implements org. Returns the initial elements that satisfy the Predicate. |
| public ImmutableOrderedMap | tap(Procedure<? super V> procedure)
Implements org. Executes the Procedure for each value of the map and returns |
| public ImmutableOrderedMap | |
| public ImmutableOrderedMap | toReversed()
Implements org. Returns a new ReversibleIterable in reverse order. |
| public String | toString()
Overrides org. Implements org. Returns a string with the keys and values of this map separated by commas with spaces and enclosed in curly braces. |
| public Collection | values()
Implements java. Returns a |
| public RichIterable | valuesView()
Implements org. Returns an unmodifiable lazy iterable wrapped around the values for the map. |
| public <S> ImmutableList | zip(Iterable<S> that)
Implements org. Returns a |
| public ImmutableList | zipWithIndex()
Implements org. Zips this |