Klasse ImmutableList<E>
java.lang.Object
ch.nolix.core.container.base.Container<E>
ch.nolix.core.container.immutablelist.ImmutableList<E>
- Typparameter:
E
- is the type of the elements of aImmutableList
.
- Alle implementierten Schnittstellen:
IContainer<E>
,IMappableContainer<E>
,ISearchableContainer<E>
,IStatisticalConainer<E>
,IterableWithCopyableIterator<E>
,StoringRequestable<E>
,EmptinessRequestable
,MaterializationRequestable
,Iterable<E>
A
ImmutableList
is a Container
that is not mutable.- Version:
- 2022-07-08
- Autor:
- Silvan Wyss
-
Konstruktorübersicht
-
Methodenübersicht
Modifizierer und TypMethodeBeschreibungprotected <E2> ILinkedList
<E2> createEmptyMutableList
(Marker<E2> marker) static <E2> ImmutableList
<E2> forArray
(E2[] array) static <E2> ImmutableList
<E2> forIterable
(Iterable<E2> container) int
getCount()
getStoredAt1BasedIndex
(int p1BasedIndex) boolean
iterator()
<C extends Comparable<C>>
IContainer<E> toOrderedList
(Function<E, C> norm) toString()
static <E2> ImmutableList
<E2> withElement
(E2 element, E2... elements) Von Klasse geerbte Methoden ch.nolix.core.container.base.Container
contains, containsAll, containsAll, containsAny, containsAny, containsAny, containsAnyOf, containsAsManyAs, containsEqualing, containsExactlyInSameOrder, containsLessThan, containsMoreThan, containsNone, containsNone, containsNoneOf, containsOnce, containsOne, containsOne, containsOneEqualing, containsOnly, containsOnlyEqualingAndViceVersa, from1BasedStartIndex, from1BasedStartIndexUntil1BasedEndIndex, get1BasedIndexOfFirst, get1BasedIndexOfFirstEqualElement, get1BasedIndexOfFirstOccuranceOf, getAverage, getAverageOrZero, getCount, getCount, getMax, getMaxOrZero, getMedian, getMedianOrZero, getMin, getMinOrZero, getOptionalStoredFirst, getOptionalStoredFirst, getStandardDeviation, getStoredAny, getStoredByMax, getStoredByMin, getStoredFirst, getStoredFirst, getStoredGroups, getStoredOfType, getStoredOne, getStoredOne, getStoredOther, getStoredSelected, getSum, getSumOfIntegers, getVariance, isEmpty, to, toArray, toByteArray, toCharArray, toConcatenatedString, toDoubleArray, toFromGroups, toIntArray, toLongArray, toReversedList, toStringArray, toStrings, toStringWithSeparator, toStringWithSeparator, until1BasedIndex, withoutFirst, withoutFirst, withoutLast, withoutLast
Von Klasse geerbte Methoden java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Von Schnittstelle geerbte Methoden java.lang.Iterable
forEach, spliterator
Von Schnittstelle geerbte Methoden ch.nolix.coreapi.stateapi.staterequestapi.MaterializationRequestable
isView
-
Konstruktordetails
-
ImmutableList
public ImmutableList()Creates a newImmutableList
that is empty.
-
-
Methodendetails
-
forArray
-
forIterable
- Typparameter:
E2
-- Parameter:
container
-- Gibt zurück:
- a new
ImmutableList
with the elements from the given container. - Löst aus:
ArgumentIsNullException
- if one of the elements of the given container is null.
-
withElement
- Typparameter:
E2
- is the type of the given element and of the given elements.- Parameter:
element
-elements
-- Gibt zurück:
- a new
ImmutableList
with the given element and elements. - Löst aus:
ArgumentIsNullException
- if the given element is null.ArgumentIsNullException
- if one of the given elements is null.
-
getCount
public int getCount()- Gibt zurück:
- the number of elements of the current
IStatisticalConainer
.
-
getStoredAt1BasedIndex
- Parameter:
p1BasedIndex
-- Gibt zurück:
- the element at the given p1BasedIndex.
-
getStoredLast
- Gibt zurück:
- the last element of the current
ISearchableContainer
.
-
isMaterialized
public boolean isMaterialized()- Gibt zurück:
- true if the current
MaterializationRequestable
is materialized, false otherwise.
-
iterator
-
toOrderedList
- Typparameter:
C
- is the type of theComparable
s the given norm returns.- Parameter:
norm
-- Gibt zurück:
- a new
IContainer
with the elements of the currentIContainer
ordered from the smallest to the biggest element according to the given norm.
-
toString
-
createEmptyMutableList
- Angegeben von:
createEmptyMutableList
in KlasseContainer<E>
- Typparameter:
E2
- is the type of the elements the createdILinkedList
can contain.- Parameter:
marker
-- Gibt zurück:
- a new empty
ILinkedList
.
-