J.6. Collections Methods

Class Collections provides several high-performance algorithms (Fig. J.5) for manipulating collection elements. The algorithms are implemented as static methods. The methods sort, binarySearch, reverse, shuffle, fill and copy operate on Lists. Methods min, max and addAll operate on Collections.

Image

Fig. J.5 | Some methods of class Collections.

Get Android™ How to Program, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.