| Package | Description |
|---|---|
| net.pterodactylus.util.collection |
| Modifier and Type | Method and Description |
|---|---|
Container<T> |
Container.add(int index,
T element)
Creates and returns a new container that contains the elements of this
container with the given element inserted at the given index.
|
Container<T> |
Container.add(T element)
Creates and returns a new container that contains all elements of this
container and the given element, which is appended at the end.
|
Container<T> |
Container.crop(int index)
Returns a container that contains only the element at the given index.
|
Container<T> |
Container.crop(int start,
int end)
Returns a container that contains a part of this container, starting at
the index
start (inclusive) and ending at the index end
(exclusive). |
Container<T> |
Container.filter(Filter<T> filter)
Filters the elements of this container through the given filter.
|
Container<T> |
Container.last()
Returns a container that only contains the last element of this
container.
|
<O> Container<O> |
Container.map(Map<T,O> map)
Maps all elements in this container using the given map and returns a
container containing the mapped elements.
|
<O> Container<O> |
Container.map(Mapper<T,O> mapper)
Maps all elements in this container using the given mapper and returns a
container containing the mapped elements.
|
Container<T> |
Container.process(Processor<T> processor)
Processes all elements in this container.
|
Container<T> |
Container.remove(int index)
Returns a container that contains the elements of this container with the
exception of the element at the given index which is removed.
|
Container<T> |
Container.remove(T element)
Returns a container that contains the elements of this container with the
exception of the first occurence of the given element which is removed.
|
Container<T> |
Container.reverse()
Returns a container with the elements of this container in reverse order.
|
Container<T> |
Container.sort()
Returns a container that contains all elements of this container sorted
by their natural order.
|
Container<T> |
Container.sort(Comparator<? super T> comparator)
Returns a container that contains all elements of this container sorted
using the given comparator.
|
Copyright © 2026. All rights reserved.