153 lines
4.5 KiB
HTML
153 lines
4.5 KiB
HTML
<title>RELEASE NOTES: COLLECTIONS 3.0</title>
|
|
|
|
<center><h2>RELEASE NOTES: COLLECTIONS 3.0</h2></center>
|
|
|
|
<p><i>Collections 3.0</i> includes a lot of new functionality, including new interfaces
|
|
and new implementations in addition to various bug fixes and refactoring changes.
|
|
The major additions are:
|
|
</p>
|
|
<ul>
|
|
<li><strong>Bidirectional maps</strong> -
|
|
New interface and implementations for maps that need bidirectional lookup.</li>
|
|
<li><strong>Map iterator</strong> -
|
|
New interface to enable iteration over map keys and values in one easy step.</li>
|
|
<li><strong>Observable collections</strong> -
|
|
New collection decorators that allow changes to collections to be observed via listeners.</li>
|
|
<li><strong>Decorators</strong> -
|
|
An entire package of classes that decorate existing collections/maps to add functionality.
|
|
This includes fixed size, lazy loading, validating, unmodifiable, synchronized, bounded,
|
|
transforming and ordered.</li>
|
|
<li><strong>Functors</strong> -
|
|
A default set of functor implementations is now provided for Predicate, Transformer,
|
|
Closure and Factory.</li>
|
|
<li><strong>Pairs</strong> -
|
|
A new package full of key-value pairs and map entry implementations.</li>
|
|
</ul>
|
|
<p>
|
|
All previously deprecated classes have been removed.
|
|
</p>
|
|
|
|
<hr />
|
|
|
|
<center><h3>
|
|
NEW PACKAGES
|
|
</h3></center>
|
|
|
|
<p>These packages are new to <i>Collections 3.0</i>:</p>
|
|
|
|
<ul>
|
|
<li><strong>decorators</strong> -
|
|
Package of classes that decorate other collections/maps. Some of these classes
|
|
were previously inner classes, others are new.</li>
|
|
|
|
<li><strong>observed</strong> -
|
|
Package of classes that enable changes to collections/maps to be observed.</li>
|
|
|
|
<li><strong>pairs</strong> -
|
|
Package of key-value pairs and map entries.</li>
|
|
</ul>
|
|
|
|
<center><h3>
|
|
NEW CLASSES
|
|
</h3></center>
|
|
|
|
<p>These collections are new to <i>Collections 3.0</i>:</p>
|
|
|
|
<ul>
|
|
</ul>
|
|
|
|
<p>These comparators are new to <i>Collections 3.0</i>:</p>
|
|
|
|
<ul>
|
|
<li><strong>BooleanIterator</strong> -
|
|
Provides a comparator over Boolean instances.</li>
|
|
|
|
<li><strong>FixedOrderIterator</strong> -
|
|
Provides an iterator in a fixed pre-determined order.</li>
|
|
</ul>
|
|
|
|
<p>These iterators are new to <i>Collections 3.0</i>:</p>
|
|
|
|
<ul>
|
|
<li><strong>MapIterator</strong> -
|
|
Interface that defines a simple and powerful way to iterate over a Map.</li>
|
|
|
|
<li><strong>Resetable*Iterator</strong> -
|
|
Interfaces that defines a reset() method to reset the iterator back to the start.</li>
|
|
|
|
<li><strong>ArrayListIterator</strong> -
|
|
Provides a ListIterator over an array of any type (including primitive arrays).</li>
|
|
|
|
<li><strong>LoopingIterator</strong> -
|
|
Provides an Iterator that loops repeatedly over the collection.</li>
|
|
|
|
<li><strong>ObjectArray*Iterator</strong> -
|
|
Provides iterators over an Object array.</li>
|
|
|
|
<li><strong>Abstract*IteratorDecorator</strong> -
|
|
Provides abstract decorators that can be used to build extra functionality.</li>
|
|
|
|
<li><strong>Unmodifiable*Iterator</strong> -
|
|
Provides decorators for iterators that are unmodifiable.</li>
|
|
</ul>
|
|
|
|
<p>These are the new utility classes:</p>
|
|
|
|
<ul>
|
|
</ul>
|
|
|
|
|
|
<hr />
|
|
|
|
<center><h3>CHANGED CLASSES</h3></center>
|
|
|
|
<p>These comparators have changed since <i>Collections 3.0</i>:</p>
|
|
|
|
<ul>
|
|
<li><strong>ComparableComparator</strong> -
|
|
Simpler implementation that respects interface better.</li>
|
|
|
|
<li><strong>ComparatorChain</strong> -
|
|
Equals and HashCode added.</li>
|
|
|
|
<li><strong>ReverseComparator</strong> -
|
|
Equals and HashCode added.</li>
|
|
</ul>
|
|
|
|
<p>These iterators have changed since <i>Collections 3.0</i>:</p>
|
|
|
|
<ul>
|
|
<li><strong>ArrayIterator</strong> -
|
|
This now implements the ResetableIterator interface. It also supports a start index to iterate from.</li>
|
|
|
|
<li><strong>CollatingIterator</strong> -
|
|
The remove() method now throws IllegalStateException not NoSuchElementException.</li>
|
|
|
|
<li><strong>FilterIterator</strong> -
|
|
The remove() method is now supported, with some limitations.</li>
|
|
|
|
<li><strong>IteratorChain</strong> -
|
|
Bug fix for when remove() called before hasNext()/next().</li>
|
|
|
|
<li><strong>Singleton*Iterator</strong> -
|
|
These now implement the ResetableIterator interface.</li>
|
|
|
|
<li><strong>Proxy*Iterator</strong> -
|
|
Now deprecated in favour of AbstractIteratorDecorator/AbstractListIteratorDecorator.</li>
|
|
|
|
<li><strong>Filter*Iterator/TransformIterator</strong> -
|
|
No longer extend ProxyIterator.</li>
|
|
</ul>
|
|
|
|
|
|
<hr />
|
|
|
|
|
|
<center><h3>REFACTORING</h3></center>
|
|
|
|
<p><u>Documentation</u></p>
|
|
|
|
<p>Every class released in 3.0 has been changed in some way.
|
|
This might be simply the update to the Apache license, or it could be improved Javadoc.</p>
|
|
|