Skip to main content

AList

Complete API reference for AList, including constructors, attributes, virtual attributes, and methods.

Package: JAVARuntime

Category: Lists

Component: no


public class AList

Constructors

SignatureDescription
AList()Creates a new instance of AList.
AList([List<T>])Creates a new instance of AList.

Methods

SignatureReturnsDescription
size()intReturns the list size (number of elements).
isEmpty()booleanReturns whether the list is empty.
contains(Object)booleanReturns whether the list contains the element.
iterator()Iterator<T>Returns an iterator over the elements in the list.
toArray()Object[]Returns an array with all elements in the list.
toArray(E[])E[]Returns an array with all elements in the list, using the provided array.
add(T)booleanAdd the element to the list.
remove(Object)booleanRemoves the element from the list.
addAll(Collection<? extends T>)booleanAdds all the elements from the collection to the list.
addAll(int, Collection<? extends T>)booleanAdds all the elements from the collection to the list at the specified index.
clear()voidRemoves all elements from the list.
equals(Object)booleanCompares whether the list is equal to the specified object.
hashCode()intReturns the hash code of the list.
get(int)TReturns the element at the specified index.
set(int, T)TSets the element at the index to the provided value.
add(int, T)voidAdds the element at the specified index.
remove(int)TRemoves the element at the specified index.
indexOf(Object)intReturns the index of the first occurrence of the specified element.
lastIndexOf(Object)intReturns the index of the last occurrence of the specified element.
listIterator()ListIterator<T>Returns a list iterator over the elements in the list.
listIterator(int)ListIterator<T>Returns a list iterator over the elements in the list, starting at the specified index.
subList(int, int)List<T>Returns a list of elements between specified indices.
retainAll(Collection<?>)booleanRetains only the elements in the list that are contained in the specified collection.
removeAll(Collection<?>)booleanRemoves from the list all elements that have the same value from the specified collection.
containsAll(Collection<?>)booleanChecks if the list contains all elements of the specified collection.
forEach(Consumer<? super T>)voidExecutes the given action for each element in the list.
replaceAll(UnaryOperator<T>)voidReplaces each element with the result of applying the operator.
sort(Comparator<? super T>)voidSorts the list using the provided comparator.
removeIf(Predicate<? super T>)booleanRemoves all elements that satisfy the given predicate.
spliterator()Spliterator<T>Returns a spliterator over the elements in the list.
stream()Stream<T>Returns a sequential stream of the list.
parallelStream()Stream<T>Returns a possibly parallel stream of the list.
getInternalList()List<T>Returns the internal list (for advanced use).