> For the complete documentation index, see [llms.txt](https://avbravo-2.gitbook.io/trucosjakartaee/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://avbravo-2.gitbook.io/trucosjakartaee/overview/java-8/brownies-collections.md).

# Brownies Collections

Brownies Collections complements the Java Collections Framework. The

[Classes](http://www.magicwerk.org/page-collections-classes.html)

sections contains an illustration to give you an overview of all the available functionality.

<http://www.magicwerk.org/page-collections-overview.html>

**GapList**combines the strengths of both ArrayList and LinkedList. It is implemented to offer both efficient random access to elements by index (as ArrayList does) and at the same time efficient adding and removing elements to and from beginning and end (as LinkedList does). It also exploits the locality of reference often seen in applications to further improve performance, e.g. for iterating over the list.

* **BigList**is a list optimized for storing large number of elements. It stores the elements in fixed size blocks so for adding and removing only few elements must be moved. Blocks are split or merged as needed and maintained in a tree for fast access. Copying a BigList is very efficient as it is implemented using a copy-on-write approach.
* Both GapList and BigList have been designed to be used as**drop-in replacement**for ArrayList, LinkedList or ArrayDeque by offering all their methods. Additionally many more helpful methods are available provided by the common abstract class IList.
