Top Description Fields Constructors Methods
org.eclipse.collections.impl.list.immutable

pack-priv final Class ImmutableDecapletonList<T>

extends AbstractImmutableList<T>
implements Serializable, RandomAccess
Class Inheritance
All Implemented Interfaces
java.util.RandomAccess, java.io.Serializable
Imports
java.io.Serializable, java.util.RandomAccess, org.eclipse.collections.api.block.procedure.Procedure, org.eclipse.collections.api.factory.Lists, org.eclipse.collections.api.list.ImmutableList

This is a ten element immutable List which is created by calling Immutable.newListWith(one, two, three, four, five, six, seven, eight, nine, ten) method.

Field Summary

Modifier and TypeField and Description
private final T
private final T
private final T
private final T
private final T
private final T
private final T
private final T
private final T
private final T
private static final long

Constructor Summary

AccessConstructor and Description
pack-priv
ImmutableDecapletonList(T obj1, T obj2, T obj3, T obj4, T obj5, T obj6, T obj7, T obj8, T obj9, T obj10)

Method Summary

Modifier and TypeMethod and Description
public void
each(Procedure<? super T> procedure)

Implements org.eclipse.collections.api.RichIterable.each.

The procedure is executed for each element in the iterable.

public T
get(int index)

Implements org.eclipse.collections.api.list.ListIterable.get, java.util.List.get.

Returns the element at the specified position in this list.

public T
getOnly()

Overrides default org.eclipse.collections.api.RichIterable.getOnly.

Returns the element if the iterable has exactly one element.

public ImmutableList<T>
newWith(T newItem)

Implements org.eclipse.collections.api.list.ImmutableList.newWith, org.eclipse.collections.api.collection.ImmutableCollection.newWith.

This method is similar to the with method in MutableCollection with the difference that a new copy of this collection with the element appended will be returned.

public int
size()

Implements org.eclipse.collections.api.RichIterable.size, java.util.List.size, java.util.Collection.size.

Returns the number of elements in this list.

Inherited from org.eclipse.collections.impl.list.immutable.AbstractImmutableList:
addaddAllappendStringasParallelasReversedcastToListchunkcollectcollectBooleancollectBytecollectCharcollectDoublecollectFloatcollectIfcollectIntcollectLongcollectShortcollectWithcollectWithcorrespondscountdetectIndexdetectLastIndexdistinctdistinctdistinctBydropdropWhileequalsflatCollectflatCollectforEachforEachWithforEachWithIndexforEachWithIndexgetFirstgetLastgroupBygroupBygroupByEachgroupByEachhashCodeindexOfinjectIntoinjectIntoinjectIntoinjectIntoinjectIntoiteratorlastIndexOflistIteratorlistIteratormaxmaxmaxByminminminBynewMutablenewWithAllnewWithoutnewWithoutAllpartitionpartitionWhilepartitionWithregularListEqualsrejectrejectWithrejectWithremovereplaceAllselectselectInstancesOfselectWithselectWithsetsortsubListsumOfDoublesumOfFloatsumOfIntsumOfLongtaketakeWhiletaptoImmutabletoReversedzipzipWithIndex

Field Detail

element1back to summary
private final T element1
element10back to summary
private final T element10
element2back to summary
private final T element2
element3back to summary
private final T element3
element4back to summary
private final T element4
element5back to summary
private final T element5
element6back to summary
private final T element6
element7back to summary
private final T element7
element8back to summary
private final T element8
element9back to summary
private final T element9
serialVersionUIDback to summary
private static final long serialVersionUID

Constructor Detail

ImmutableDecapletonListback to summary
pack-priv ImmutableDecapletonList(T obj1, T obj2, T obj3, T obj4, T obj5, T obj6, T obj7, T obj8, T obj9, T obj10)

Method Detail

eachback to summary
public void each(Procedure<? super T> procedure)

Implements org.eclipse.collections.api.RichIterable.each.

Doc from org.eclipse.collections.api.RichIterable.each.

The procedure is executed for each element in the iterable.

Example using a Java 8 lambda expression:

people.each(person -> LOGGER.info(person.getName()));
This method is a variant of InternalIterable#forEach(Procedure) that has a signature conflict with Iterable#forEach(java.util.function.Consumer).
Annotations
@Override
getback to summary
public T get(int index)

Implements org.eclipse.collections.api.list.ListIterable.get, java.util.List.get.

Doc from java.util.List.get.

Returns the element at the specified position in this list.

Annotations
@Override
getOnlyback to summary
public T getOnly()

Overrides default org.eclipse.collections.api.RichIterable.getOnly.

Doc from org.eclipse.collections.api.RichIterable.getOnly.

Returns the element if the iterable has exactly one element. Otherwise, throw IllegalStateException.

Annotations
@Override
newWithback to summary
public ImmutableList<T> newWith(T newItem)

Implements org.eclipse.collections.api.list.ImmutableList.newWith, org.eclipse.collections.api.collection.ImmutableCollection.newWith.

Doc from org.eclipse.collections.api.collection.ImmutableCollection.newWith.

This method is similar to the with method in MutableCollection with the difference that a new copy of this collection with the element appended will be returned.

Annotations
@Override
sizeback to summary
public int size()

Implements org.eclipse.collections.api.RichIterable.size, java.util.List.size, java.util.Collection.size.

Doc from java.util.List.size.

Returns the number of elements in this list. If this list contains more than Integer.MAX_VALUE elements, returns Integer.MAX_VALUE.

Annotations
@Override