blob: e9b241286b3e5b71a22e5fd5e423c132ddf0f52a [file] [log] [blame]
<!DOCTYPE HTML>
<!-- NewPage -->
<html lang="en">
<head>
<!-- Generated by javadoc (14.0.2) on Thu Aug 20 21:25:36 CDT 2020 -->
<title>AbstractHashBag (Eclipse Collections - 10.4.0)</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta name="dc.created" content="2020-08-20">
<meta name="description" content="declaration: package: org.eclipse.collections.impl.bag.mutable, class: AbstractHashBag">
<meta name="generator" content="javadoc/ClassWriterImpl">
<link rel="stylesheet" type="text/css" href="../../../../../../stylesheet.css" title="Style">
<link rel="stylesheet" type="text/css" href="../../../../../../script-dir/jquery-ui.css" title="Style">
<script type="text/javascript" src="../../../../../../script.js"></script>
<script type="text/javascript" src="../../../../../../script-dir/jszip/dist/jszip.min.js"></script>
<script type="text/javascript" src="../../../../../../script-dir/jszip-utils/dist/jszip-utils.min.js"></script>
<!--[if IE]>
<script type="text/javascript" src="../../../../../../script-dir/jszip-utils/dist/jszip-utils-ie.min.js"></script>
<![endif]-->
<script type="text/javascript" src="../../../../../../script-dir/jquery-3.4.1.js"></script>
<script type="text/javascript" src="../../../../../../script-dir/jquery-ui.js"></script>
</head>
<body class="class-declaration">
<script type="text/javascript">var data = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10};
var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]};
var altColor = "altColor";
var rowColor = "rowColor";
var tableTab = "tableTab";
var activeTableTab = "activeTableTab";
var pathtoroot = "../../../../../../";
loadScripts(document, 'script');</script>
<noscript>
<div>JavaScript is disabled on your browser.</div>
</noscript>
<div class="flexBox">
<header role="banner" class="flexHeader">
<nav role="navigation">
<!-- ========= START OF TOP NAVBAR ======= -->
<div class="topNav"><a id="navbar.top">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.top" title="Skip navigation links">Skip navigation links</a></div>
<a id="navbar.top.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/AbstractHashBag.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
<div class="navListSearch"><label for="search">SEARCH:</label>
<input type="text" id="search" value="search" disabled="disabled">
<input type="reset" id="reset" value="reset" disabled="disabled">
</div>
</div>
<!-- ========= END OF TOP NAVBAR ========= -->
<div class="skipNav"><a id="skip.navbar.top">
<!-- -->
</a></div>
</nav>
</header>
<div class="flexContent">
<main role="main">
<!-- ======== START OF CLASS DATA ======== -->
<div class="header">
<div class="subTitle"><span class="packageLabelInType">Package</span>&nbsp;<a href="package-summary.html">org.eclipse.collections.impl.bag.mutable</a></div>
<h1 title="Class AbstractHashBag" class="title">Class AbstractHashBag&lt;T&gt;</h1>
</div>
<div class="contentContainer">
<div class="inheritance" title="Inheritance Tree"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">java.lang.Object</a>
<div class="inheritance"><a href="../../AbstractRichIterable.html" title="class in org.eclipse.collections.impl">org.eclipse.collections.impl.AbstractRichIterable</a>&lt;T&gt;
<div class="inheritance"><a href="../AbstractBag.html" title="class in org.eclipse.collections.impl.bag">org.eclipse.collections.impl.bag.AbstractBag</a>&lt;T&gt;
<div class="inheritance"><a href="AbstractMutableBagIterable.html" title="class in org.eclipse.collections.impl.bag.mutable">org.eclipse.collections.impl.bag.mutable.AbstractMutableBagIterable</a>&lt;T&gt;
<div class="inheritance"><a href="AbstractMutableBag.html" title="class in org.eclipse.collections.impl.bag.mutable">org.eclipse.collections.impl.bag.mutable.AbstractMutableBag</a>&lt;T&gt;
<div class="inheritance">org.eclipse.collections.impl.bag.mutable.AbstractHashBag&lt;T&gt;</div>
</div>
</div>
</div>
</div>
</div>
<section class="description">
<dl>
<dt>All Implemented Interfaces:</dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a>&lt;T&gt;</code>, <code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a>&lt;T&gt;</code>, <code><a href="../../../api/bag/Bag.html" title="interface in org.eclipse.collections.api.bag">Bag</a>&lt;T&gt;</code>, <code><a href="../../../api/bag/MutableBag.html" title="interface in org.eclipse.collections.api.bag">MutableBag</a>&lt;T&gt;</code>, <code><a href="../../../api/bag/MutableBagIterable.html" title="interface in org.eclipse.collections.api.bag">MutableBagIterable</a>&lt;T&gt;</code>, <code><a href="../../../api/bag/UnsortedBag.html" title="interface in org.eclipse.collections.api.bag">UnsortedBag</a>&lt;T&gt;</code>, <code><a href="../../../api/collection/MutableCollection.html" title="interface in org.eclipse.collections.api.collection">MutableCollection</a>&lt;T&gt;</code>, <code><a href="../../../api/InternalIterable.html" title="interface in org.eclipse.collections.api">InternalIterable</a>&lt;T&gt;</code>, <code><a href="../../../api/RichIterable.html" title="interface in org.eclipse.collections.api">RichIterable</a>&lt;T&gt;</code></dd>
</dl>
<dl>
<dt>Direct Known Subclasses:</dt>
<dd><code><a href="HashBag.html" title="class in org.eclipse.collections.impl.bag.mutable">HashBag</a></code>, <code><a href="../strategy/mutable/HashBagWithHashingStrategy.html" title="class in org.eclipse.collections.impl.bag.strategy.mutable">HashBagWithHashingStrategy</a></code></dd>
</dl>
<hr>
<pre>public abstract class <span class="typeNameLabel">AbstractHashBag&lt;T&gt;</span>
extends <a href="AbstractMutableBag.html" title="class in org.eclipse.collections.impl.bag.mutable">AbstractMutableBag</a>&lt;T&gt;</pre>
</section>
<section class="summary">
<ul class="blockList">
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<li class="blockList">
<section class="constructorSummary"><a id="constructor.summary">
<!-- -->
</a>
<h2>Constructor Summary</h2>
<div class="memberSummary">
<table>
<caption><span>Constructors</span><span class="tabEnd">&nbsp;</span></caption>
<thead>
<tr>
<th class="colFirst" scope="col">Constructor</th>
<th class="colLast" scope="col">Description</th>
</tr>
</thead>
<tbody>
<tr class="altColor">
<th class="colConstructorName" scope="row"><code><span class="memberNameLink"><a href="#%3Cinit%3E()">AbstractHashBag</a></span>()</code></th>
<td class="colLast">&nbsp;</td>
</tr>
</tbody>
</table>
</div>
</section>
</li>
<!-- ========== METHOD SUMMARY =========== -->
<li class="blockList">
<section class="methodSummary"><a id="method.summary">
<!-- -->
</a>
<h2>Method Summary</h2>
<div class="memberSummary">
<div role="tablist" aria-orientation="horizontal"><button role="tab" aria-selected="true" aria-controls="memberSummary_tabpanel" tabindex="0" onkeydown="switchTab(event)" id="t0" class="activeTableTab">All Methods</button><button role="tab" aria-selected="false" aria-controls="memberSummary_tabpanel" tabindex="-1" onkeydown="switchTab(event)" id="t2" class="tableTab" onclick="show(2);">Instance Methods</button><button role="tab" aria-selected="false" aria-controls="memberSummary_tabpanel" tabindex="-1" onkeydown="switchTab(event)" id="t4" class="tableTab" onclick="show(8);">Concrete Methods</button></div>
<div id="memberSummary_tabpanel" role="tabpanel">
<table aria-labelledby="t0">
<thead>
<tr>
<th class="colFirst" scope="col">Modifier and Type</th>
<th class="colSecond" scope="col">Method</th>
<th class="colLast" scope="col">Description</th>
</tr>
</thead>
<tbody>
<tr class="altColor" id="i0">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#add(T)">add</a></span>&#8203;(<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&nbsp;item)</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="rowColor" id="i1">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#addOccurrences(T,int)">addOccurrences</a></span>&#8203;(<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&nbsp;item,
int&nbsp;occurrences)</code></th>
<td class="colLast">
<div class="block">Add number of <code>occurrences</code> for an <code>item</code>.</div>
</td>
</tr>
<tr class="altColor" id="i2">
<td class="colFirst"><code>void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#clear()">clear</a></span>()</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="rowColor" id="i3">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#contains(java.lang.Object)">contains</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;o)</code></th>
<td class="colLast">
<div class="block">Returns true if the iterable has an element which responds true to element.equals(object).</div>
</td>
</tr>
<tr class="altColor" id="i4">
<td class="colFirst"><code>void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#each(org.eclipse.collections.api.block.procedure.Procedure)">each</a></span>&#8203;(<a href="../../../api/block/procedure/Procedure.html" title="interface in org.eclipse.collections.api.block.procedure">Procedure</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;procedure)</code></th>
<td class="colLast">
<div class="block">The procedure is executed for each element in the iterable.</div>
</td>
</tr>
<tr class="rowColor" id="i5">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#equals(java.lang.Object)">equals</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;other)</code></th>
<td class="colLast">
<div class="block">Two bags <code>b1</code> and <code>b2</code> are equal if <code>m1.toMapOfItemToCount().equals(m2.toMapOfItemToCount())</code>.</div>
</td>
</tr>
<tr class="altColor" id="i6">
<td class="colFirst"><code>&lt;P&gt;&nbsp;void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#forEachWith(org.eclipse.collections.api.block.procedure.Procedure2,P)">forEachWith</a></span>&#8203;(<a href="../../../api/block/procedure/Procedure2.html" title="interface in org.eclipse.collections.api.block.procedure">Procedure2</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? super P&gt;&nbsp;procedure,
P&nbsp;parameter)</code></th>
<td class="colLast">
<div class="block">The procedure2 is evaluated for each element in the iterable with the specified parameter provided
as the second argument.</div>
</td>
</tr>
<tr class="rowColor" id="i7">
<td class="colFirst"><code>void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#forEachWithIndex(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">forEachWithIndex</a></span>&#8203;(<a href="../../../api/block/procedure/primitive/ObjectIntProcedure.html" title="interface in org.eclipse.collections.api.block.procedure.primitive">ObjectIntProcedure</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;objectIntProcedure)</code></th>
<td class="colLast">
<div class="block">Iterates over the iterable passing each element and the current relative int index to the specified instance of
ObjectIntProcedure.</div>
</td>
</tr>
<tr class="altColor" id="i8">
<td class="colFirst"><code>void</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#forEachWithOccurrences(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">forEachWithOccurrences</a></span>&#8203;(<a href="../../../api/block/procedure/primitive/ObjectIntProcedure.html" title="interface in org.eclipse.collections.api.block.procedure.primitive">ObjectIntProcedure</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;objectIntProcedure)</code></th>
<td class="colLast">
<div class="block">For each distinct item, with the number of occurrences, execute the specified procedure.</div>
</td>
</tr>
<tr class="rowColor" id="i9">
<td class="colFirst"><code>&lt;V&gt;&nbsp;<a href="../../multimap/bag/HashBagMultimap.html" title="class in org.eclipse.collections.impl.multimap.bag">HashBagMultimap</a>&lt;V,&#8203;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#groupBy(org.eclipse.collections.api.block.function.Function)">groupBy</a></span>&#8203;(<a href="../../../api/block/function/Function.html" title="interface in org.eclipse.collections.api.block.function">Function</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? extends V&gt;&nbsp;function)</code></th>
<td class="colLast">
<div class="block">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.</div>
</td>
</tr>
<tr class="altColor" id="i10">
<td class="colFirst"><code>&lt;V&gt;&nbsp;<a href="../../multimap/bag/HashBagMultimap.html" title="class in org.eclipse.collections.impl.multimap.bag">HashBagMultimap</a>&lt;V,&#8203;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#groupByEach(org.eclipse.collections.api.block.function.Function)">groupByEach</a></span>&#8203;(<a href="../../../api/block/function/Function.html" title="interface in org.eclipse.collections.api.block.function">Function</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a>&lt;V&gt;&gt;&nbsp;function)</code></th>
<td class="colLast">
<div class="block">Similar to <a href="../../../api/RichIterable.html#groupBy(org.eclipse.collections.api.block.function.Function)"><code>RichIterable.groupBy(Function)</code></a>, except the result of evaluating function will return a collection of keys
for each value.</div>
</td>
</tr>
<tr class="rowColor" id="i11">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#hashCode()">hashCode</a></span>()</code></th>
<td class="colLast">
<div class="block">Returns the hash code for this Bag, defined as <em>this.<a href="../../../api/bag/Bag.html#toMapOfItemToCount()"><code>Bag.toMapOfItemToCount()</code></a>.hashCode()</em>.</div>
</td>
</tr>
<tr class="altColor" id="i12">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#isEmpty()">isEmpty</a></span>()</code></th>
<td class="colLast">
<div class="block">Returns true if this iterable has zero items.</div>
</td>
</tr>
<tr class="rowColor" id="i13">
<td class="colFirst"><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util" class="externalLink">Iterator</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#iterator()">iterator</a></span>()</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="altColor" id="i14">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#occurrencesOf(java.lang.Object)">occurrencesOf</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;item)</code></th>
<td class="colLast">
<div class="block">The occurrences of a distinct item in the bag.</div>
</td>
</tr>
<tr class="rowColor" id="i15">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#remove(java.lang.Object)">remove</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;item)</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="altColor" id="i16">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#removeAllIterable(java.lang.Iterable)">removeAllIterable</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a>&lt;?&gt;&nbsp;iterable)</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="rowColor" id="i17">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#removeIf(org.eclipse.collections.api.block.predicate.Predicate)">removeIf</a></span>&#8203;(<a href="../../../api/block/predicate/Predicate.html" title="interface in org.eclipse.collections.api.block.predicate">Predicate</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;predicate)</code></th>
<td class="colLast">
<div class="block">Removes all elements in the collection that evaluate to true for the specified predicate.</div>
</td>
</tr>
<tr class="altColor" id="i18">
<td class="colFirst"><code>&lt;P&gt;&nbsp;boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#removeIfWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">removeIfWith</a></span>&#8203;(<a href="../../../api/block/predicate/Predicate2.html" title="interface in org.eclipse.collections.api.block.predicate">Predicate2</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? super P&gt;&nbsp;predicate,
P&nbsp;parameter)</code></th>
<td class="colLast">
<div class="block">Removes all elements in the collection that evaluate to true for the specified predicate2 and parameter.</div>
</td>
</tr>
<tr class="rowColor" id="i19">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#removeOccurrences(java.lang.Object,int)">removeOccurrences</a></span>&#8203;(<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;item,
int&nbsp;occurrences)</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="altColor" id="i20">
<td class="colFirst"><code>boolean</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#setOccurrences(T,int)">setOccurrences</a></span>&#8203;(<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&nbsp;item,
int&nbsp;occurrences)</code></th>
<td class="colLast">&nbsp;</td>
</tr>
<tr class="rowColor" id="i21">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#size()">size</a></span>()</code></th>
<td class="colLast">
<div class="block">Returns the number of items in this iterable.</div>
</td>
</tr>
<tr class="altColor" id="i22">
<td class="colFirst"><code>int</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#sizeDistinct()">sizeDistinct</a></span>()</code></th>
<td class="colLast">
<div class="block">The size of the Bag when counting only distinct elements.</div>
</td>
</tr>
<tr class="rowColor" id="i23">
<td class="colFirst"><code><a href="../../../api/map/MutableMap.html" title="interface in org.eclipse.collections.api.map">MutableMap</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang" class="externalLink">Integer</a>&gt;</code></td>
<th class="colSecond" scope="row"><code><span class="memberNameLink"><a href="#toMapOfItemToCount()">toMapOfItemToCount</a></span>()</code></th>
<td class="colLast">
<div class="block">Converts the Bag to a Map of the Item type to its count as an Integer.</div>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.eclipse.collections.impl.bag.mutable.<a href="AbstractMutableBag.html" title="class in org.eclipse.collections.impl.bag.mutable">AbstractMutableBag</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.impl.bag.mutable.AbstractMutableBag">
<!-- -->
</a><code><a href="AbstractMutableBag.html#asParallel(java.util.concurrent.ExecutorService,int)">asParallel</a>, <a href="AbstractMutableBag.html#asSynchronized()">asSynchronized</a>, <a href="AbstractMutableBag.html#asUnmodifiable()">asUnmodifiable</a>, <a href="AbstractMutableBag.html#collect(org.eclipse.collections.api.block.function.Function)">collect</a>, <a href="AbstractMutableBag.html#collectBoolean(org.eclipse.collections.api.block.function.primitive.BooleanFunction)">collectBoolean</a>, <a href="AbstractMutableBag.html#collectByte(org.eclipse.collections.api.block.function.primitive.ByteFunction)">collectByte</a>, <a href="AbstractMutableBag.html#collectChar(org.eclipse.collections.api.block.function.primitive.CharFunction)">collectChar</a>, <a href="AbstractMutableBag.html#collectDouble(org.eclipse.collections.api.block.function.primitive.DoubleFunction)">collectDouble</a>, <a href="AbstractMutableBag.html#collectFloat(org.eclipse.collections.api.block.function.primitive.FloatFunction)">collectFloat</a>, <a href="AbstractMutableBag.html#collectIf(org.eclipse.collections.api.block.predicate.Predicate,org.eclipse.collections.api.block.function.Function)">collectIf</a>, <a href="AbstractMutableBag.html#collectInt(org.eclipse.collections.api.block.function.primitive.IntFunction)">collectInt</a>, <a href="AbstractMutableBag.html#collectLong(org.eclipse.collections.api.block.function.primitive.LongFunction)">collectLong</a>, <a href="AbstractMutableBag.html#collectShort(org.eclipse.collections.api.block.function.primitive.ShortFunction)">collectShort</a>, <a href="AbstractMutableBag.html#collectWith(org.eclipse.collections.api.block.function.Function2,P)">collectWith</a>, <a href="AbstractMutableBag.html#collectWithOccurrences(org.eclipse.collections.api.block.function.primitive.ObjectIntToObjectFunction)">collectWithOccurrences</a>, <a href="AbstractMutableBag.html#countBy(org.eclipse.collections.api.block.function.Function)">countBy</a>, <a href="AbstractMutableBag.html#countByEach(org.eclipse.collections.api.block.function.Function)">countByEach</a>, <a href="AbstractMutableBag.html#countByWith(org.eclipse.collections.api.block.function.Function2,P)">countByWith</a>, <a href="AbstractMutableBag.html#flatCollect(org.eclipse.collections.api.block.function.Function)">flatCollect</a>, <a href="AbstractMutableBag.html#partition(org.eclipse.collections.api.block.predicate.Predicate)">partition</a>, <a href="AbstractMutableBag.html#partitionWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">partitionWith</a>, <a href="AbstractMutableBag.html#reject(org.eclipse.collections.api.block.predicate.Predicate)">reject</a>, <a href="AbstractMutableBag.html#rejectWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">rejectWith</a>, <a href="AbstractMutableBag.html#select(org.eclipse.collections.api.block.predicate.Predicate)">select</a>, <a href="AbstractMutableBag.html#selectInstancesOf(java.lang.Class)">selectInstancesOf</a>, <a href="AbstractMutableBag.html#selectWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">selectWith</a>, <a href="AbstractMutableBag.html#tap(org.eclipse.collections.api.block.procedure.Procedure)">tap</a>, <a href="AbstractMutableBag.html#toImmutable()">toImmutable</a>, <a href="AbstractMutableBag.html#zip(java.lang.Iterable)">zip</a>, <a href="AbstractMutableBag.html#zipWithIndex()">zipWithIndex</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.eclipse.collections.impl.bag.mutable.<a href="AbstractMutableBagIterable.html" title="class in org.eclipse.collections.impl.bag.mutable">AbstractMutableBagIterable</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.impl.bag.mutable.AbstractMutableBagIterable">
<!-- -->
</a><code><a href="AbstractMutableBagIterable.html#addAll(java.util.Collection)">addAll</a>, <a href="AbstractMutableBagIterable.html#addAllIterable(java.lang.Iterable)">addAllIterable</a>, <a href="AbstractMutableBagIterable.html#aggregateInPlaceBy(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function0,org.eclipse.collections.api.block.procedure.Procedure2)">aggregateInPlaceBy</a>, <a href="AbstractMutableBagIterable.html#allSatisfy(org.eclipse.collections.api.block.predicate.Predicate)">allSatisfy</a>, <a href="AbstractMutableBagIterable.html#allSatisfyWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">allSatisfyWith</a>, <a href="AbstractMutableBagIterable.html#anySatisfy(org.eclipse.collections.api.block.predicate.Predicate)">anySatisfy</a>, <a href="AbstractMutableBagIterable.html#anySatisfyWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">anySatisfyWith</a>, <a href="AbstractMutableBagIterable.html#bottomOccurrences(int)">bottomOccurrences</a>, <a href="AbstractMutableBagIterable.html#chunk(int)">chunk</a>, <a href="AbstractMutableBagIterable.html#detect(org.eclipse.collections.api.block.predicate.Predicate)">detect</a>, <a href="AbstractMutableBagIterable.html#detectIfNone(org.eclipse.collections.api.block.predicate.Predicate,org.eclipse.collections.api.block.function.Function0)">detectIfNone</a>, <a href="AbstractMutableBagIterable.html#detectOptional(org.eclipse.collections.api.block.predicate.Predicate)">detectOptional</a>, <a href="AbstractMutableBagIterable.html#detectWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">detectWith</a>, <a href="AbstractMutableBagIterable.html#detectWithIfNone(org.eclipse.collections.api.block.predicate.Predicate2,P,org.eclipse.collections.api.block.function.Function0)">detectWithIfNone</a>, <a href="AbstractMutableBagIterable.html#detectWithOptional(org.eclipse.collections.api.block.predicate.Predicate2,P)">detectWithOptional</a>, <a href="AbstractMutableBagIterable.html#getFirst()">getFirst</a>, <a href="AbstractMutableBagIterable.html#getLast()">getLast</a>, <a href="AbstractMutableBagIterable.html#groupByUniqueKey(org.eclipse.collections.api.block.function.Function)">groupByUniqueKey</a>, <a href="AbstractMutableBagIterable.html#max()">max</a>, <a href="AbstractMutableBagIterable.html#max(java.util.Comparator)">max</a>, <a href="AbstractMutableBagIterable.html#maxBy(org.eclipse.collections.api.block.function.Function)">maxBy</a>, <a href="AbstractMutableBagIterable.html#min()">min</a>, <a href="AbstractMutableBagIterable.html#min(java.util.Comparator)">min</a>, <a href="AbstractMutableBagIterable.html#minBy(org.eclipse.collections.api.block.function.Function)">minBy</a>, <a href="AbstractMutableBagIterable.html#noneSatisfy(org.eclipse.collections.api.block.predicate.Predicate)">noneSatisfy</a>, <a href="AbstractMutableBagIterable.html#noneSatisfyWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">noneSatisfyWith</a>, <a href="AbstractMutableBagIterable.html#removeAll(java.util.Collection)">removeAll</a>, <a href="AbstractMutableBagIterable.html#retainAll(java.util.Collection)">retainAll</a>, <a href="AbstractMutableBagIterable.html#retainAllIterable(java.lang.Iterable)">retainAllIterable</a>, <a href="AbstractMutableBagIterable.html#selectAndRejectWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">selectAndRejectWith</a>, <a href="AbstractMutableBagIterable.html#sumByDouble(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.DoubleFunction)">sumByDouble</a>, <a href="AbstractMutableBagIterable.html#sumByFloat(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.FloatFunction)">sumByFloat</a>, <a href="AbstractMutableBagIterable.html#sumByInt(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.IntFunction)">sumByInt</a>, <a href="AbstractMutableBagIterable.html#sumByLong(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.LongFunction)">sumByLong</a>, <a href="AbstractMutableBagIterable.html#topOccurrences(int)">topOccurrences</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.eclipse.collections.impl.bag.<a href="../AbstractBag.html" title="class in org.eclipse.collections.impl.bag">AbstractBag</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.impl.bag.AbstractBag">
<!-- -->
</a><code><a href="../AbstractBag.html#collect(org.eclipse.collections.api.block.function.Function,R)">collect</a>, <a href="../AbstractBag.html#collectBoolean(org.eclipse.collections.api.block.function.primitive.BooleanFunction,R)">collectBoolean</a>, <a href="../AbstractBag.html#collectByte(org.eclipse.collections.api.block.function.primitive.ByteFunction,R)">collectByte</a>, <a href="../AbstractBag.html#collectChar(org.eclipse.collections.api.block.function.primitive.CharFunction,R)">collectChar</a>, <a href="../AbstractBag.html#collectDouble(org.eclipse.collections.api.block.function.primitive.DoubleFunction,R)">collectDouble</a>, <a href="../AbstractBag.html#collectFloat(org.eclipse.collections.api.block.function.primitive.FloatFunction,R)">collectFloat</a>, <a href="../AbstractBag.html#collectIf(org.eclipse.collections.api.block.predicate.Predicate,org.eclipse.collections.api.block.function.Function,R)">collectIf</a>, <a href="../AbstractBag.html#collectInt(org.eclipse.collections.api.block.function.primitive.IntFunction,R)">collectInt</a>, <a href="../AbstractBag.html#collectLong(org.eclipse.collections.api.block.function.primitive.LongFunction,R)">collectLong</a>, <a href="../AbstractBag.html#collectShort(org.eclipse.collections.api.block.function.primitive.ShortFunction,R)">collectShort</a>, <a href="../AbstractBag.html#collectWith(org.eclipse.collections.api.block.function.Function2,P,R)">collectWith</a>, <a href="../AbstractBag.html#count(org.eclipse.collections.api.block.predicate.Predicate)">count</a>, <a href="../AbstractBag.html#flatCollect(org.eclipse.collections.api.block.function.Function,R)">flatCollect</a>, <a href="../AbstractBag.html#flatCollectBoolean(org.eclipse.collections.api.block.function.Function,R)">flatCollectBoolean</a>, <a href="../AbstractBag.html#flatCollectByte(org.eclipse.collections.api.block.function.Function,R)">flatCollectByte</a>, <a href="../AbstractBag.html#flatCollectChar(org.eclipse.collections.api.block.function.Function,R)">flatCollectChar</a>, <a href="../AbstractBag.html#flatCollectDouble(org.eclipse.collections.api.block.function.Function,R)">flatCollectDouble</a>, <a href="../AbstractBag.html#flatCollectFloat(org.eclipse.collections.api.block.function.Function,R)">flatCollectFloat</a>, <a href="../AbstractBag.html#flatCollectInt(org.eclipse.collections.api.block.function.Function,R)">flatCollectInt</a>, <a href="../AbstractBag.html#flatCollectLong(org.eclipse.collections.api.block.function.Function,R)">flatCollectLong</a>, <a href="../AbstractBag.html#flatCollectShort(org.eclipse.collections.api.block.function.Function,R)">flatCollectShort</a>, <a href="../AbstractBag.html#groupBy(org.eclipse.collections.api.block.function.Function,R)">groupBy</a>, <a href="../AbstractBag.html#groupByEach(org.eclipse.collections.api.block.function.Function,R)">groupByEach</a>, <a href="../AbstractBag.html#injectInto(double,org.eclipse.collections.api.block.function.primitive.DoubleObjectToDoubleFunction)">injectInto</a>, <a href="../AbstractBag.html#injectInto(float,org.eclipse.collections.api.block.function.primitive.FloatObjectToFloatFunction)">injectInto</a>, <a href="../AbstractBag.html#injectInto(int,org.eclipse.collections.api.block.function.primitive.IntObjectToIntFunction)">injectInto</a>, <a href="../AbstractBag.html#injectInto(long,org.eclipse.collections.api.block.function.primitive.LongObjectToLongFunction)">injectInto</a>, <a href="../AbstractBag.html#injectInto(IV,org.eclipse.collections.api.block.function.Function2)">injectInto</a>, <a href="../AbstractBag.html#injectIntoWith(IV,org.eclipse.collections.api.block.function.Function3,P)">injectIntoWith</a>, <a href="../AbstractBag.html#reject(org.eclipse.collections.api.block.predicate.Predicate,R)">reject</a>, <a href="../AbstractBag.html#rejectWith(org.eclipse.collections.api.block.predicate.Predicate2,P,R)">rejectWith</a>, <a href="../AbstractBag.html#select(org.eclipse.collections.api.block.predicate.Predicate,R)">select</a>, <a href="../AbstractBag.html#selectWith(org.eclipse.collections.api.block.predicate.Predicate2,P,R)">selectWith</a>, <a href="../AbstractBag.html#sumOfDouble(org.eclipse.collections.api.block.function.primitive.DoubleFunction)">sumOfDouble</a>, <a href="../AbstractBag.html#sumOfFloat(org.eclipse.collections.api.block.function.primitive.FloatFunction)">sumOfFloat</a>, <a href="../AbstractBag.html#sumOfInt(org.eclipse.collections.api.block.function.primitive.IntFunction)">sumOfInt</a>, <a href="../AbstractBag.html#sumOfLong(org.eclipse.collections.api.block.function.primitive.LongFunction)">sumOfLong</a>, <a href="../AbstractBag.html#toBag()">toBag</a>, <a href="../AbstractBag.html#toList()">toList</a>, <a href="../AbstractBag.html#toSet()">toSet</a>, <a href="../AbstractBag.html#toSortedBag()">toSortedBag</a>, <a href="../AbstractBag.html#toSortedBag(java.util.Comparator)">toSortedBag</a>, <a href="../AbstractBag.html#toSortedList(java.util.Comparator)">toSortedList</a>, <a href="../AbstractBag.html#toSortedSet()">toSortedSet</a>, <a href="../AbstractBag.html#toSortedSet(java.util.Comparator)">toSortedSet</a>, <a href="../AbstractBag.html#toStringOfItemToCount()">toStringOfItemToCount</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;org.eclipse.collections.impl.<a href="../../AbstractRichIterable.html" title="class in org.eclipse.collections.impl">AbstractRichIterable</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.impl.AbstractRichIterable">
<!-- -->
</a><code><a href="../../AbstractRichIterable.html#appendString(java.lang.Appendable,java.lang.String)">appendString</a>, <a href="../../AbstractRichIterable.html#appendString(java.lang.Appendable,java.lang.String,java.lang.String,java.lang.String)">appendString</a>, <a href="../../AbstractRichIterable.html#asLazy()">asLazy</a>, <a href="../../AbstractRichIterable.html#containsAll(java.util.Collection)">containsAll</a>, <a href="../../AbstractRichIterable.html#containsAllArguments(java.lang.Object...)">containsAllArguments</a>, <a href="../../AbstractRichIterable.html#containsAllIterable(java.lang.Iterable)">containsAllIterable</a>, <a href="../../AbstractRichIterable.html#countWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">countWith</a>, <a href="../../AbstractRichIterable.html#forEach(org.eclipse.collections.api.block.procedure.Procedure)">forEach</a>, <a href="../../AbstractRichIterable.html#groupByUniqueKey(org.eclipse.collections.api.block.function.Function,R)">groupByUniqueKey</a>, <a href="../../AbstractRichIterable.html#into(R)">into</a>, <a href="../../AbstractRichIterable.html#toArray()">toArray</a>, <a href="../../AbstractRichIterable.html#toArray(E%5B%5D)">toArray</a>, <a href="../../AbstractRichIterable.html#toBiMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toBiMap</a>, <a href="../../AbstractRichIterable.html#toMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toMap</a>, <a href="../../AbstractRichIterable.html#toSortedBagBy(org.eclipse.collections.api.block.function.Function)">toSortedBagBy</a>, <a href="../../AbstractRichIterable.html#toSortedListBy(org.eclipse.collections.api.block.function.Function)">toSortedListBy</a>, <a href="../../AbstractRichIterable.html#toSortedMap(java.util.Comparator,org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toSortedMap</a>, <a href="../../AbstractRichIterable.html#toSortedMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toSortedMap</a>, <a href="../../AbstractRichIterable.html#toSortedMapBy(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toSortedMapBy</a>, <a href="../../AbstractRichIterable.html#toSortedSetBy(org.eclipse.collections.api.block.function.Function)">toSortedSetBy</a>, <a href="../../AbstractRichIterable.html#toString()">toString</a>, <a href="../../AbstractRichIterable.html#zip(java.lang.Iterable,R)">zip</a>, <a href="../../AbstractRichIterable.html#zipWithIndex(R)">zipWithIndex</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from class&nbsp;java.lang.<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></h3>
<a id="methods.inherited.from.class.java.lang.Object">
<!-- -->
</a><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#getClass()" title="class or interface in java.lang" class="externalLink">getClass</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notify()" title="class or interface in java.lang" class="externalLink">notify</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#notifyAll()" title="class or interface in java.lang" class="externalLink">notifyAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait()" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long)" title="class or interface in java.lang" class="externalLink">wait</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#wait(long,int)" title="class or interface in java.lang" class="externalLink">wait</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;org.eclipse.collections.api.bag.<a href="../../../api/bag/Bag.html" title="interface in org.eclipse.collections.api.bag">Bag</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.api.bag.Bag">
<!-- -->
</a><code><a href="../../../api/bag/Bag.html#aggregateBy(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function0,org.eclipse.collections.api.block.function.Function2,R)">aggregateBy</a>, <a href="../../../api/bag/Bag.html#collectWithOccurrences(org.eclipse.collections.api.block.function.primitive.ObjectIntToObjectFunction,R)">collectWithOccurrences</a>, <a href="../../../api/bag/Bag.html#reduceInPlace(java.util.function.Supplier,java.util.function.BiConsumer)">reduceInPlace</a>, <a href="../../../api/bag/Bag.html#reduceInPlace(java.util.stream.Collector)">reduceInPlace</a>, <a href="../../../api/bag/Bag.html#summarizeDouble(org.eclipse.collections.api.block.function.primitive.DoubleFunction)">summarizeDouble</a>, <a href="../../../api/bag/Bag.html#summarizeFloat(org.eclipse.collections.api.block.function.primitive.FloatFunction)">summarizeFloat</a>, <a href="../../../api/bag/Bag.html#summarizeInt(org.eclipse.collections.api.block.function.primitive.IntFunction)">summarizeInt</a>, <a href="../../../api/bag/Bag.html#summarizeLong(org.eclipse.collections.api.block.function.primitive.LongFunction)">summarizeLong</a>, <a href="../../../api/bag/Bag.html#toStringOfItemToCount()">toStringOfItemToCount</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;java.util.<a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a></h3>
<a id="methods.inherited.from.class.java.util.Collection">
<!-- -->
</a><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#addAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">addAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#containsAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">containsAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#parallelStream()" title="class or interface in java.util" class="externalLink">parallelStream</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#removeAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">removeAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#removeIf(java.util.function.Predicate)" title="class or interface in java.util" class="externalLink">removeIf</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#retainAll(java.util.Collection)" title="class or interface in java.util" class="externalLink">retainAll</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#spliterator()" title="class or interface in java.util" class="externalLink">spliterator</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#stream()" title="class or interface in java.util" class="externalLink">stream</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#toArray()" title="class or interface in java.util" class="externalLink">toArray</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#toArray(java.util.function.IntFunction)" title="class or interface in java.util" class="externalLink">toArray</a>, <a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#toArray(T%5B%5D)" title="class or interface in java.util" class="externalLink">toArray</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;org.eclipse.collections.api.<a href="../../../api/InternalIterable.html" title="interface in org.eclipse.collections.api">InternalIterable</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.api.InternalIterable">
<!-- -->
</a><code><a href="../../../api/InternalIterable.html#forEach(java.util.function.Consumer)">forEach</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;org.eclipse.collections.api.bag.<a href="../../../api/bag/MutableBag.html" title="interface in org.eclipse.collections.api.bag">MutableBag</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.api.bag.MutableBag">
<!-- -->
</a><code><a href="../../../api/bag/MutableBag.html#flatCollectWith(org.eclipse.collections.api.block.function.Function2,P)">flatCollectWith</a>, <a href="../../../api/bag/MutableBag.html#newEmpty()">newEmpty</a>, <a href="../../../api/bag/MutableBag.html#selectByOccurrences(org.eclipse.collections.api.block.predicate.primitive.IntPredicate)">selectByOccurrences</a>, <a href="../../../api/bag/MutableBag.html#selectDuplicates()">selectDuplicates</a>, <a href="../../../api/bag/MutableBag.html#selectUnique()">selectUnique</a>, <a href="../../../api/bag/MutableBag.html#with(T)">with</a>, <a href="../../../api/bag/MutableBag.html#withAll(java.lang.Iterable)">withAll</a>, <a href="../../../api/bag/MutableBag.html#without(T)">without</a>, <a href="../../../api/bag/MutableBag.html#withoutAll(java.lang.Iterable)">withoutAll</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;org.eclipse.collections.api.bag.<a href="../../../api/bag/MutableBagIterable.html" title="interface in org.eclipse.collections.api.bag">MutableBagIterable</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.api.bag.MutableBagIterable">
<!-- -->
</a><code><a href="../../../api/bag/MutableBagIterable.html#bottomOccurrences(int)">bottomOccurrences</a>, <a href="../../../api/bag/MutableBagIterable.html#selectByOccurrences(org.eclipse.collections.api.block.predicate.primitive.IntPredicate)">selectByOccurrences</a>, <a href="../../../api/bag/MutableBagIterable.html#selectDuplicates()">selectDuplicates</a>, <a href="../../../api/bag/MutableBagIterable.html#selectUnique()">selectUnique</a>, <a href="../../../api/bag/MutableBagIterable.html#topOccurrences(int)">topOccurrences</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;org.eclipse.collections.api.collection.<a href="../../../api/collection/MutableCollection.html" title="interface in org.eclipse.collections.api.collection">MutableCollection</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.api.collection.MutableCollection">
<!-- -->
</a><code><a href="../../../api/collection/MutableCollection.html#addAllIterable(java.lang.Iterable)">addAllIterable</a>, <a href="../../../api/collection/MutableCollection.html#aggregateBy(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function0,org.eclipse.collections.api.block.function.Function2)">aggregateBy</a>, <a href="../../../api/collection/MutableCollection.html#aggregateInPlaceBy(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function0,org.eclipse.collections.api.block.procedure.Procedure2)">aggregateInPlaceBy</a>, <a href="../../../api/collection/MutableCollection.html#flatCollectWith(org.eclipse.collections.api.block.function.Function2,P)">flatCollectWith</a>, <a href="../../../api/collection/MutableCollection.html#groupByUniqueKey(org.eclipse.collections.api.block.function.Function)">groupByUniqueKey</a>, <a href="../../../api/collection/MutableCollection.html#injectIntoWith(IV,org.eclipse.collections.api.block.function.Function3,P)">injectIntoWith</a>, <a href="../../../api/collection/MutableCollection.html#retainAllIterable(java.lang.Iterable)">retainAllIterable</a>, <a href="../../../api/collection/MutableCollection.html#selectAndRejectWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">selectAndRejectWith</a>, <a href="../../../api/collection/MutableCollection.html#sumByDouble(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.DoubleFunction)">sumByDouble</a>, <a href="../../../api/collection/MutableCollection.html#sumByFloat(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.FloatFunction)">sumByFloat</a>, <a href="../../../api/collection/MutableCollection.html#sumByInt(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.IntFunction)">sumByInt</a>, <a href="../../../api/collection/MutableCollection.html#sumByLong(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.primitive.LongFunction)">sumByLong</a></code></div>
<div class="inheritedList">
<h3>Methods inherited from interface&nbsp;org.eclipse.collections.api.<a href="../../../api/RichIterable.html" title="interface in org.eclipse.collections.api">RichIterable</a></h3>
<a id="methods.inherited.from.class.org.eclipse.collections.api.RichIterable">
<!-- -->
</a><code><a href="../../../api/RichIterable.html#allSatisfy(org.eclipse.collections.api.block.predicate.Predicate)">allSatisfy</a>, <a href="../../../api/RichIterable.html#allSatisfyWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">allSatisfyWith</a>, <a href="../../../api/RichIterable.html#anySatisfy(org.eclipse.collections.api.block.predicate.Predicate)">anySatisfy</a>, <a href="../../../api/RichIterable.html#anySatisfyWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">anySatisfyWith</a>, <a href="../../../api/RichIterable.html#appendString(java.lang.Appendable)">appendString</a>, <a href="../../../api/RichIterable.html#appendString(java.lang.Appendable,java.lang.String)">appendString</a>, <a href="../../../api/RichIterable.html#appendString(java.lang.Appendable,java.lang.String,java.lang.String,java.lang.String)">appendString</a>, <a href="../../../api/RichIterable.html#asLazy()">asLazy</a>, <a href="../../../api/RichIterable.html#chunk(int)">chunk</a>, <a href="../../../api/RichIterable.html#collect(org.eclipse.collections.api.block.function.Function,R)">collect</a>, <a href="../../../api/RichIterable.html#collectBoolean(org.eclipse.collections.api.block.function.primitive.BooleanFunction,R)">collectBoolean</a>, <a href="../../../api/RichIterable.html#collectByte(org.eclipse.collections.api.block.function.primitive.ByteFunction,R)">collectByte</a>, <a href="../../../api/RichIterable.html#collectChar(org.eclipse.collections.api.block.function.primitive.CharFunction,R)">collectChar</a>, <a href="../../../api/RichIterable.html#collectDouble(org.eclipse.collections.api.block.function.primitive.DoubleFunction,R)">collectDouble</a>, <a href="../../../api/RichIterable.html#collectFloat(org.eclipse.collections.api.block.function.primitive.FloatFunction,R)">collectFloat</a>, <a href="../../../api/RichIterable.html#collectIf(org.eclipse.collections.api.block.predicate.Predicate,org.eclipse.collections.api.block.function.Function,R)">collectIf</a>, <a href="../../../api/RichIterable.html#collectInt(org.eclipse.collections.api.block.function.primitive.IntFunction,R)">collectInt</a>, <a href="../../../api/RichIterable.html#collectLong(org.eclipse.collections.api.block.function.primitive.LongFunction,R)">collectLong</a>, <a href="../../../api/RichIterable.html#collectShort(org.eclipse.collections.api.block.function.primitive.ShortFunction,R)">collectShort</a>, <a href="../../../api/RichIterable.html#collectWith(org.eclipse.collections.api.block.function.Function2,P,R)">collectWith</a>, <a href="../../../api/RichIterable.html#containsAll(java.util.Collection)">containsAll</a>, <a href="../../../api/RichIterable.html#containsAllArguments(java.lang.Object...)">containsAllArguments</a>, <a href="../../../api/RichIterable.html#containsAllIterable(java.lang.Iterable)">containsAllIterable</a>, <a href="../../../api/RichIterable.html#containsBy(org.eclipse.collections.api.block.function.Function,V)">containsBy</a>, <a href="../../../api/RichIterable.html#count(org.eclipse.collections.api.block.predicate.Predicate)">count</a>, <a href="../../../api/RichIterable.html#countBy(org.eclipse.collections.api.block.function.Function,R)">countBy</a>, <a href="../../../api/RichIterable.html#countByEach(org.eclipse.collections.api.block.function.Function,R)">countByEach</a>, <a href="../../../api/RichIterable.html#countByWith(org.eclipse.collections.api.block.function.Function2,P,R)">countByWith</a>, <a href="../../../api/RichIterable.html#countWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">countWith</a>, <a href="../../../api/RichIterable.html#detect(org.eclipse.collections.api.block.predicate.Predicate)">detect</a>, <a href="../../../api/RichIterable.html#detectIfNone(org.eclipse.collections.api.block.predicate.Predicate,org.eclipse.collections.api.block.function.Function0)">detectIfNone</a>, <a href="../../../api/RichIterable.html#detectOptional(org.eclipse.collections.api.block.predicate.Predicate)">detectOptional</a>, <a href="../../../api/RichIterable.html#detectWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">detectWith</a>, <a href="../../../api/RichIterable.html#detectWithIfNone(org.eclipse.collections.api.block.predicate.Predicate2,P,org.eclipse.collections.api.block.function.Function0)">detectWithIfNone</a>, <a href="../../../api/RichIterable.html#detectWithOptional(org.eclipse.collections.api.block.predicate.Predicate2,P)">detectWithOptional</a>, <a href="../../../api/RichIterable.html#flatCollect(org.eclipse.collections.api.block.function.Function,R)">flatCollect</a>, <a href="../../../api/RichIterable.html#flatCollectBoolean(org.eclipse.collections.api.block.function.Function,R)">flatCollectBoolean</a>, <a href="../../../api/RichIterable.html#flatCollectByte(org.eclipse.collections.api.block.function.Function,R)">flatCollectByte</a>, <a href="../../../api/RichIterable.html#flatCollectChar(org.eclipse.collections.api.block.function.Function,R)">flatCollectChar</a>, <a href="../../../api/RichIterable.html#flatCollectDouble(org.eclipse.collections.api.block.function.Function,R)">flatCollectDouble</a>, <a href="../../../api/RichIterable.html#flatCollectFloat(org.eclipse.collections.api.block.function.Function,R)">flatCollectFloat</a>, <a href="../../../api/RichIterable.html#flatCollectInt(org.eclipse.collections.api.block.function.Function,R)">flatCollectInt</a>, <a href="../../../api/RichIterable.html#flatCollectLong(org.eclipse.collections.api.block.function.Function,R)">flatCollectLong</a>, <a href="../../../api/RichIterable.html#flatCollectShort(org.eclipse.collections.api.block.function.Function,R)">flatCollectShort</a>, <a href="../../../api/RichIterable.html#flatCollectWith(org.eclipse.collections.api.block.function.Function2,P,R)">flatCollectWith</a>, <a href="../../../api/RichIterable.html#forEach(org.eclipse.collections.api.block.procedure.Procedure)">forEach</a>, <a href="../../../api/RichIterable.html#getAny()">getAny</a>, <a href="../../../api/RichIterable.html#getFirst()">getFirst</a>, <a href="../../../api/RichIterable.html#getLast()">getLast</a>, <a href="../../../api/RichIterable.html#getOnly()">getOnly</a>, <a href="../../../api/RichIterable.html#groupBy(org.eclipse.collections.api.block.function.Function,R)">groupBy</a>, <a href="../../../api/RichIterable.html#groupByAndCollect(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function,R)">groupByAndCollect</a>, <a href="../../../api/RichIterable.html#groupByEach(org.eclipse.collections.api.block.function.Function,R)">groupByEach</a>, <a href="../../../api/RichIterable.html#groupByUniqueKey(org.eclipse.collections.api.block.function.Function,R)">groupByUniqueKey</a>, <a href="../../../api/RichIterable.html#injectInto(double,org.eclipse.collections.api.block.function.primitive.DoubleObjectToDoubleFunction)">injectInto</a>, <a href="../../../api/RichIterable.html#injectInto(float,org.eclipse.collections.api.block.function.primitive.FloatObjectToFloatFunction)">injectInto</a>, <a href="../../../api/RichIterable.html#injectInto(int,org.eclipse.collections.api.block.function.primitive.IntObjectToIntFunction)">injectInto</a>, <a href="../../../api/RichIterable.html#injectInto(long,org.eclipse.collections.api.block.function.primitive.LongObjectToLongFunction)">injectInto</a>, <a href="../../../api/RichIterable.html#injectInto(IV,org.eclipse.collections.api.block.function.Function2)">injectInto</a>, <a href="../../../api/RichIterable.html#into(R)">into</a>, <a href="../../../api/RichIterable.html#makeString()">makeString</a>, <a href="../../../api/RichIterable.html#makeString(java.lang.String)">makeString</a>, <a href="../../../api/RichIterable.html#makeString(java.lang.String,java.lang.String,java.lang.String)">makeString</a>, <a href="../../../api/RichIterable.html#max()">max</a>, <a href="../../../api/RichIterable.html#max(java.util.Comparator)">max</a>, <a href="../../../api/RichIterable.html#maxBy(org.eclipse.collections.api.block.function.Function)">maxBy</a>, <a href="../../../api/RichIterable.html#maxByOptional(org.eclipse.collections.api.block.function.Function)">maxByOptional</a>, <a href="../../../api/RichIterable.html#maxOptional()">maxOptional</a>, <a href="../../../api/RichIterable.html#maxOptional(java.util.Comparator)">maxOptional</a>, <a href="../../../api/RichIterable.html#min()">min</a>, <a href="../../../api/RichIterable.html#min(java.util.Comparator)">min</a>, <a href="../../../api/RichIterable.html#minBy(org.eclipse.collections.api.block.function.Function)">minBy</a>, <a href="../../../api/RichIterable.html#minByOptional(org.eclipse.collections.api.block.function.Function)">minByOptional</a>, <a href="../../../api/RichIterable.html#minOptional()">minOptional</a>, <a href="../../../api/RichIterable.html#minOptional(java.util.Comparator)">minOptional</a>, <a href="../../../api/RichIterable.html#noneSatisfy(org.eclipse.collections.api.block.predicate.Predicate)">noneSatisfy</a>, <a href="../../../api/RichIterable.html#noneSatisfyWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">noneSatisfyWith</a>, <a href="../../../api/RichIterable.html#notEmpty()">notEmpty</a>, <a href="../../../api/RichIterable.html#reduce(java.util.function.BinaryOperator)">reduce</a>, <a href="../../../api/RichIterable.html#reject(org.eclipse.collections.api.block.predicate.Predicate,R)">reject</a>, <a href="../../../api/RichIterable.html#rejectWith(org.eclipse.collections.api.block.predicate.Predicate2,P,R)">rejectWith</a>, <a href="../../../api/RichIterable.html#select(org.eclipse.collections.api.block.predicate.Predicate,R)">select</a>, <a href="../../../api/RichIterable.html#selectWith(org.eclipse.collections.api.block.predicate.Predicate2,P,R)">selectWith</a>, <a href="../../../api/RichIterable.html#sumOfDouble(org.eclipse.collections.api.block.function.primitive.DoubleFunction)">sumOfDouble</a>, <a href="../../../api/RichIterable.html#sumOfFloat(org.eclipse.collections.api.block.function.primitive.FloatFunction)">sumOfFloat</a>, <a href="../../../api/RichIterable.html#sumOfInt(org.eclipse.collections.api.block.function.primitive.IntFunction)">sumOfInt</a>, <a href="../../../api/RichIterable.html#sumOfLong(org.eclipse.collections.api.block.function.primitive.LongFunction)">sumOfLong</a>, <a href="../../../api/RichIterable.html#toArray()">toArray</a>, <a href="../../../api/RichIterable.html#toArray(E%5B%5D)">toArray</a>, <a href="../../../api/RichIterable.html#toBag()">toBag</a>, <a href="../../../api/RichIterable.html#toBiMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toBiMap</a>, <a href="../../../api/RichIterable.html#toList()">toList</a>, <a href="../../../api/RichIterable.html#toMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toMap</a>, <a href="../../../api/RichIterable.html#toMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function,R)">toMap</a>, <a href="../../../api/RichIterable.html#toSet()">toSet</a>, <a href="../../../api/RichIterable.html#toSortedBag()">toSortedBag</a>, <a href="../../../api/RichIterable.html#toSortedBag(java.util.Comparator)">toSortedBag</a>, <a href="../../../api/RichIterable.html#toSortedBagBy(org.eclipse.collections.api.block.function.Function)">toSortedBagBy</a>, <a href="../../../api/RichIterable.html#toSortedList()">toSortedList</a>, <a href="../../../api/RichIterable.html#toSortedList(java.util.Comparator)">toSortedList</a>, <a href="../../../api/RichIterable.html#toSortedListBy(org.eclipse.collections.api.block.function.Function)">toSortedListBy</a>, <a href="../../../api/RichIterable.html#toSortedMap(java.util.Comparator,org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toSortedMap</a>, <a href="../../../api/RichIterable.html#toSortedMap(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toSortedMap</a>, <a href="../../../api/RichIterable.html#toSortedMapBy(org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function,org.eclipse.collections.api.block.function.Function)">toSortedMapBy</a>, <a href="../../../api/RichIterable.html#toSortedSet()">toSortedSet</a>, <a href="../../../api/RichIterable.html#toSortedSet(java.util.Comparator)">toSortedSet</a>, <a href="../../../api/RichIterable.html#toSortedSetBy(org.eclipse.collections.api.block.function.Function)">toSortedSetBy</a>, <a href="../../../api/RichIterable.html#toString()">toString</a>, <a href="../../../api/RichIterable.html#zip(java.lang.Iterable,R)">zip</a>, <a href="../../../api/RichIterable.html#zipWithIndex(R)">zipWithIndex</a></code></div>
</section>
</li>
</ul>
</section>
<section class="details">
<ul class="blockList">
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<li class="blockList">
<section class="constructorDetails"><a id="constructor.detail">
<!-- -->
</a>
<h2>Constructor Details</h2>
<ul class="blockList">
<li class="blockList">
<section class="detail">
<h3><a id="&lt;init&gt;()">AbstractHashBag</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="memberName">AbstractHashBag</span>()</div>
</section>
</li>
</ul>
</section>
</li>
<!-- ============ METHOD DETAIL ========== -->
<li class="blockList">
<section class="methodDetails"><a id="method.detail">
<!-- -->
</a>
<h2>Method Details</h2>
<ul class="blockList">
<li class="blockList">
<section class="detail">
<h3><a id="addOccurrences(java.lang.Object,int)">
<!-- -->
</a><a id="addOccurrences(T,int)">addOccurrences</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">int</span>&nbsp;<span class="memberName">addOccurrences</span>&#8203;(<span class="arguments"><a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&nbsp;item,
int&nbsp;occurrences)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/MutableBagIterable.html#addOccurrences(T,int)">MutableBagIterable</a></code></span></div>
<div class="block">Add number of <code>occurrences</code> for an <code>item</code>. If the <code>item</code> does not exist, then the <code>item</code> is added to the bag.
<p>
For Example:
<pre>
MutableBagIterable&lt;String&gt; names = Bags.mutable.of("A", "B", "B");
Assert.assertEquals(4, names.<b>addOccurrences</b>("A", 3));
</pre></div>
<dl>
<dt><span class="returnLabel">Returns:</span></dt>
<dd>updated number of occurrences.</dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="equals(java.lang.Object)">equals</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">equals</span>&#8203;(<span class="arguments"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;other)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/Bag.html#equals(java.lang.Object)">Bag</a></code></span></div>
<div class="block">Two bags <code>b1</code> and <code>b2</code> are equal if <code>m1.toMapOfItemToCount().equals(m2.toMapOfItemToCount())</code>.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../api/bag/Bag.html#equals(java.lang.Object)">equals</a></code>&nbsp;in interface&nbsp;<code><a href="../../../api/bag/Bag.html" title="interface in org.eclipse.collections.api.bag">Bag</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.util" class="externalLink">equals</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.lang" class="externalLink">equals</a></code>&nbsp;in class&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></code></dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true#equals(java.lang.Object)" title="class or interface in java.util" class="externalLink"><code>Map.equals(Object)</code></a></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="hashCode()">hashCode</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">int</span>&nbsp;<span class="memberName">hashCode</span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/Bag.html#hashCode()">Bag</a></code></span></div>
<div class="block">Returns the hash code for this Bag, defined as <em>this.<a href="../../../api/bag/Bag.html#toMapOfItemToCount()"><code>Bag.toMapOfItemToCount()</code></a>.hashCode()</em>.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../api/bag/Bag.html#hashCode()">hashCode</a></code>&nbsp;in interface&nbsp;<code><a href="../../../api/bag/Bag.html" title="interface in org.eclipse.collections.api.bag">Bag</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#hashCode()" title="class or interface in java.util" class="externalLink">hashCode</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true#hashCode()" title="class or interface in java.lang" class="externalLink">hashCode</a></code>&nbsp;in class&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a></code></dd>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Map.html?is-external=true#hashCode()" title="class or interface in java.util" class="externalLink"><code>Map.hashCode()</code></a></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="sizeDistinct()">sizeDistinct</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">int</span>&nbsp;<span class="memberName">sizeDistinct</span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/Bag.html#sizeDistinct()">Bag</a></code></span></div>
<div class="block">The size of the Bag when counting only distinct elements.</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="occurrencesOf(java.lang.Object)">occurrencesOf</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">int</span>&nbsp;<span class="memberName">occurrencesOf</span>&#8203;(<span class="arguments"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;item)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/Bag.html#occurrencesOf(java.lang.Object)">Bag</a></code></span></div>
<div class="block">The occurrences of a distinct item in the bag.</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="forEachWithOccurrences(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">forEachWithOccurrences</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">void</span>&nbsp;<span class="memberName">forEachWithOccurrences</span>&#8203;(<span class="arguments"><a href="../../../api/block/procedure/primitive/ObjectIntProcedure.html" title="interface in org.eclipse.collections.api.block.procedure.primitive">ObjectIntProcedure</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;objectIntProcedure)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/Bag.html#forEachWithOccurrences(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">Bag</a></code></span></div>
<div class="block">For each distinct item, with the number of occurrences, execute the specified procedure.</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="toMapOfItemToCount()">toMapOfItemToCount</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="../../../api/map/MutableMap.html" title="interface in org.eclipse.collections.api.map">MutableMap</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Integer.html?is-external=true" title="class or interface in java.lang" class="externalLink">Integer</a>&gt;</span>&nbsp;<span class="memberName">toMapOfItemToCount</span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/bag/Bag.html#toMapOfItemToCount()">Bag</a></code></span></div>
<div class="block">Converts the Bag to a Map of the Item type to its count as an Integer.</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="add(java.lang.Object)">
<!-- -->
</a><a id="add(T)">add</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">add</span>&#8203;(<span class="arguments"><a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&nbsp;item)</span></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="remove(java.lang.Object)">remove</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">remove</span>&#8203;(<span class="arguments"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;item)</span></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="clear()">clear</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">void</span>&nbsp;<span class="memberName">clear</span>()</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="isEmpty()">isEmpty</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">isEmpty</span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/RichIterable.html#isEmpty()">RichIterable</a></code></span></div>
<div class="block">Returns true if this iterable has zero items.</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#isEmpty()" title="class or interface in java.util" class="externalLink">isEmpty</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../api/RichIterable.html#isEmpty()">isEmpty</a></code>&nbsp;in interface&nbsp;<code><a href="../../../api/RichIterable.html" title="interface in org.eclipse.collections.api">RichIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../../AbstractRichIterable.html#isEmpty()">isEmpty</a></code>&nbsp;in class&nbsp;<code><a href="../../AbstractRichIterable.html" title="class in org.eclipse.collections.impl">AbstractRichIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="each(org.eclipse.collections.api.block.procedure.Procedure)">each</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">void</span>&nbsp;<span class="memberName">each</span>&#8203;(<span class="arguments"><a href="../../../api/block/procedure/Procedure.html" title="interface in org.eclipse.collections.api.block.procedure">Procedure</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;procedure)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/RichIterable.html#each(org.eclipse.collections.api.block.procedure.Procedure)">RichIterable</a></code></span></div>
<div class="block">The procedure is executed for each element in the iterable.
<p>
Example using a Java 8 lambda expression:
<pre>
people.each(person -&gt; LOGGER.info(person.getName()));
</pre>
<p>
Example using an anonymous inner class:
<pre>
people.each(new Procedure&lt;Person&gt;()
{
public void value(Person person)
{
LOGGER.info(person.getName());
}
});
</pre>
This method is a variant of <a href="../../../api/InternalIterable.html#forEach(org.eclipse.collections.api.block.procedure.Procedure)"><code>InternalIterable.forEach(Procedure)</code></a>
that has a signature conflict with <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#forEach(java.util.function.Consumer)" title="class or interface in java.lang" class="externalLink"><code>Iterable.forEach(java.util.function.Consumer)</code></a>.</div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="../../../api/InternalIterable.html#forEach(org.eclipse.collections.api.block.procedure.Procedure)"><code>InternalIterable.forEach(Procedure)</code></a>,
<a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true#forEach(java.util.function.Consumer)" title="class or interface in java.lang" class="externalLink"><code>Iterable.forEach(java.util.function.Consumer)</code></a></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="forEachWithIndex(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">forEachWithIndex</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">void</span>&nbsp;<span class="memberName">forEachWithIndex</span>&#8203;(<span class="arguments"><a href="../../../api/block/procedure/primitive/ObjectIntProcedure.html" title="interface in org.eclipse.collections.api.block.procedure.primitive">ObjectIntProcedure</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;objectIntProcedure)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/InternalIterable.html#forEachWithIndex(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">InternalIterable</a></code></span></div>
<div class="block">Iterates over the iterable passing each element and the current relative int index to the specified instance of
ObjectIntProcedure.
<p>
Example using a Java 8 lambda:
<pre>
people.forEachWithIndex((Person person, int index) -&gt; LOGGER.info("Index: " + index + " person: " + person.getName()));
</pre>
<p>
Example using an anonymous inner class:
<pre>
people.forEachWithIndex(new ObjectIntProcedure&lt;Person&gt;()
{
public void value(Person person, int index)
{
LOGGER.info("Index: " + index + " person: " + person.getName());
}
});
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../api/InternalIterable.html#forEachWithIndex(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">forEachWithIndex</a></code>&nbsp;in interface&nbsp;<code><a href="../../../api/InternalIterable.html" title="interface in org.eclipse.collections.api">InternalIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../../AbstractRichIterable.html#forEachWithIndex(org.eclipse.collections.api.block.procedure.primitive.ObjectIntProcedure)">forEachWithIndex</a></code>&nbsp;in class&nbsp;<code><a href="../../AbstractRichIterable.html" title="class in org.eclipse.collections.impl">AbstractRichIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="forEachWith(org.eclipse.collections.api.block.procedure.Procedure2,java.lang.Object)">
<!-- -->
</a><a id="forEachWith(org.eclipse.collections.api.block.procedure.Procedure2,P)">forEachWith</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="typeParameters">&lt;P&gt;</span>&nbsp;<span class="returnType">void</span>&nbsp;<span class="memberName">forEachWith</span>&#8203;(<span class="arguments"><a href="../../../api/block/procedure/Procedure2.html" title="interface in org.eclipse.collections.api.block.procedure">Procedure2</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? super P&gt;&nbsp;procedure,
P&nbsp;parameter)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/InternalIterable.html#forEachWith(org.eclipse.collections.api.block.procedure.Procedure2,P)">InternalIterable</a></code></span></div>
<div class="block">The procedure2 is evaluated for each element in the iterable with the specified parameter provided
as the second argument.
<p>
Example using a Java 8 lambda:
<pre>
people.forEachWith((Person person, Person other) -&gt;
{
if (person.isRelatedTo(other))
{
LOGGER.info(person.getName());
}
}, fred);
</pre>
<p>
Example using an anonymous inner class:
<pre>
people.forEachWith(new Procedure2&lt;Person, Person&gt;()
{
public void value(Person person, Person other)
{
if (person.isRelatedTo(other))
{
LOGGER.info(person.getName());
}
}
}, fred);
</pre></div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../api/InternalIterable.html#forEachWith(org.eclipse.collections.api.block.procedure.Procedure2,P)">forEachWith</a></code>&nbsp;in interface&nbsp;<code><a href="../../../api/InternalIterable.html" title="interface in org.eclipse.collections.api">InternalIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../../AbstractRichIterable.html#forEachWith(org.eclipse.collections.api.block.procedure.Procedure2,P)">forEachWith</a></code>&nbsp;in class&nbsp;<code><a href="../../AbstractRichIterable.html" title="class in org.eclipse.collections.impl">AbstractRichIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="iterator()">iterator</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType"><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Iterator.html?is-external=true" title="class or interface in java.util" class="externalLink">Iterator</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</span>&nbsp;<span class="memberName">iterator</span>()</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="removeOccurrences(java.lang.Object,int)">removeOccurrences</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">removeOccurrences</span>&#8203;(<span class="arguments"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;item,
int&nbsp;occurrences)</span></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="setOccurrences(java.lang.Object,int)">
<!-- -->
</a><a id="setOccurrences(T,int)">setOccurrences</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">setOccurrences</span>&#8203;(<span class="arguments"><a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&nbsp;item,
int&nbsp;occurrences)</span></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="removeIf(org.eclipse.collections.api.block.predicate.Predicate)">removeIf</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">removeIf</span>&#8203;(<span class="arguments"><a href="../../../api/block/predicate/Predicate.html" title="interface in org.eclipse.collections.api.block.predicate">Predicate</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;&nbsp;predicate)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/collection/MutableCollection.html#removeIf(org.eclipse.collections.api.block.predicate.Predicate)">MutableCollection</a></code></span></div>
<div class="block">Removes all elements in the collection that evaluate to true for the specified predicate.
<pre>e.g.
return lastNames.<b>removeIf</b>(Predicates.isNull());
</pre></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="removeIfWith(org.eclipse.collections.api.block.predicate.Predicate2,java.lang.Object)">
<!-- -->
</a><a id="removeIfWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">removeIfWith</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="typeParameters">&lt;P&gt;</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">removeIfWith</span>&#8203;(<span class="arguments"><a href="../../../api/block/predicate/Predicate2.html" title="interface in org.eclipse.collections.api.block.predicate">Predicate2</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? super P&gt;&nbsp;predicate,
P&nbsp;parameter)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/collection/MutableCollection.html#removeIfWith(org.eclipse.collections.api.block.predicate.Predicate2,P)">MutableCollection</a></code></span></div>
<div class="block">Removes all elements in the collection that evaluate to true for the specified predicate2 and parameter.
<pre>
return lastNames.<b>removeIfWith</b>(Predicates2.isNull(), null);
</pre></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="removeAllIterable(java.lang.Iterable)">removeAllIterable</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">removeAllIterable</span>&#8203;(<span class="arguments"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a>&lt;?&gt;&nbsp;iterable)</span></div>
<dl>
<dt><span class="seeLabel">See Also:</span></dt>
<dd><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#removeAll(java.util.Collection)" title="class or interface in java.util" class="externalLink"><code>Collection.removeAll(Collection)</code></a></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="size()">size</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">int</span>&nbsp;<span class="memberName">size</span>()</div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/RichIterable.html#size()">RichIterable</a></code></span></div>
<div class="block">Returns the number of items in this iterable.</div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="contains(java.lang.Object)">contains</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="returnType">boolean</span>&nbsp;<span class="memberName">contains</span>&#8203;(<span class="arguments"><a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Object.html?is-external=true" title="class or interface in java.lang" class="externalLink">Object</a>&nbsp;o)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/RichIterable.html#contains(java.lang.Object)">RichIterable</a></code></span></div>
<div class="block">Returns true if the iterable has an element which responds true to element.equals(object).</div>
<dl>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true#contains(java.lang.Object)" title="class or interface in java.util" class="externalLink">contains</a></code>&nbsp;in interface&nbsp;<code><a href="https://docs.oracle.com/javase/8/docs/api/java/util/Collection.html?is-external=true" title="class or interface in java.util" class="externalLink">Collection</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Specified by:</span></dt>
<dd><code><a href="../../../api/RichIterable.html#contains(java.lang.Object)">contains</a></code>&nbsp;in interface&nbsp;<code><a href="../../../api/RichIterable.html" title="interface in org.eclipse.collections.api">RichIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
<dt><span class="overrideSpecifyLabel">Overrides:</span></dt>
<dd><code><a href="../../AbstractRichIterable.html#contains(java.lang.Object)">contains</a></code>&nbsp;in class&nbsp;<code><a href="../../AbstractRichIterable.html" title="class in org.eclipse.collections.impl">AbstractRichIterable</a>&lt;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</code></dd>
</dl>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="groupBy(org.eclipse.collections.api.block.function.Function)">groupBy</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="typeParameters">&lt;V&gt;</span>&nbsp;<span class="returnType"><a href="../../multimap/bag/HashBagMultimap.html" title="class in org.eclipse.collections.impl.multimap.bag">HashBagMultimap</a>&lt;V,&#8203;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</span>&nbsp;<span class="memberName">groupBy</span>&#8203;(<span class="arguments"><a href="../../../api/block/function/Function.html" title="interface in org.eclipse.collections.api.block.function">Function</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? extends V&gt;&nbsp;function)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/RichIterable.html#groupBy(org.eclipse.collections.api.block.function.Function)">RichIterable</a></code></span></div>
<div class="block">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.
<p>
Example using a Java 8 method reference:
<pre>
Multimap&lt;String, Person&gt; peopleByLastName =
people.groupBy(Person::getLastName);
</pre>
<p>
Example using an anonymous inner class:
<pre>
Multimap&lt;String, Person&gt; peopleByLastName =
people.groupBy(new Function&lt;Person, String&gt;()
{
public String valueOf(Person person)
{
return person.getLastName();
}
});
</pre></div>
</section>
</li>
<li class="blockList">
<section class="detail">
<h3><a id="groupByEach(org.eclipse.collections.api.block.function.Function)">groupByEach</a></h3>
<div class="memberSignature"><span class="modifiers">public</span>&nbsp;<span class="typeParameters">&lt;V&gt;</span>&nbsp;<span class="returnType"><a href="../../multimap/bag/HashBagMultimap.html" title="class in org.eclipse.collections.impl.multimap.bag">HashBagMultimap</a>&lt;V,&#8203;<a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>&gt;</span>&nbsp;<span class="memberName">groupByEach</span>&#8203;(<span class="arguments"><a href="../../../api/block/function/Function.html" title="interface in org.eclipse.collections.api.block.function">Function</a>&lt;? super <a href="AbstractHashBag.html" title="type parameter in AbstractHashBag">T</a>,&#8203;? extends <a href="https://docs.oracle.com/javase/8/docs/api/java/lang/Iterable.html?is-external=true" title="class or interface in java.lang" class="externalLink">Iterable</a>&lt;V&gt;&gt;&nbsp;function)</span></div>
<div class="block"><span class="descfrmTypeLabel">Description copied from interface:&nbsp;<code><a href="../../../api/RichIterable.html#groupByEach(org.eclipse.collections.api.block.function.Function)">RichIterable</a></code></span></div>
<div class="block">Similar to <a href="../../../api/RichIterable.html#groupBy(org.eclipse.collections.api.block.function.Function)"><code>RichIterable.groupBy(Function)</code></a>, except the result of evaluating function will return a collection of keys
for each value.</div>
</section>
</li>
</ul>
</section>
</li>
</ul>
</section>
</div>
<!-- ========= END OF CLASS DATA ========= -->
</main>
<footer role="contentinfo">
<nav role="navigation">
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<div class="bottomNav"><a id="navbar.bottom">
<!-- -->
</a>
<div class="skipNav"><a href="#skip.navbar.bottom" title="Skip navigation links">Skip navigation links</a></div>
<a id="navbar.bottom.firstrow">
<!-- -->
</a>
<ul class="navList" title="Navigation">
<li><a href="../../../../../../index.html">Overview</a></li>
<li><a href="package-summary.html">Package</a></li>
<li class="navBarCell1Rev">Class</li>
<li><a href="class-use/AbstractHashBag.html">Use</a></li>
<li><a href="package-tree.html">Tree</a></li>
<li><a href="../../../../../../deprecated-list.html">Deprecated</a></li>
<li><a href="../../../../../../index-all.html">Index</a></li>
<li><a href="../../../../../../help-doc.html">Help</a></li>
</ul>
</div>
<div class="subNav">
<div>
<ul class="subNavList">
<li>Summary:&nbsp;</li>
<li>Nested&nbsp;|&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.summary">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.summary">Method</a></li>
</ul>
<ul class="subNavList">
<li>Detail:&nbsp;</li>
<li>Field&nbsp;|&nbsp;</li>
<li><a href="#constructor.detail">Constr</a>&nbsp;|&nbsp;</li>
<li><a href="#method.detail">Method</a></li>
</ul>
</div>
</div>
<a id="skip.navbar.bottom">
<!-- -->
</a>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
</nav>
<p class="legalCopy"><small>Copyright &#169; 2004&#x2013;2020. All rights reserved.</small></p>
</footer>
</div>
</div>
</body>
</html>