Interface IContainer<E>
- Type Parameters:
E- is the type of the elements of aIContainer.
- All Superinterfaces:
AggregationRequestable<E>, ArrayMappable<E>, CountRequestable<E>, EmptinessRequestable, Filterable<E>, Groupable<E>, IFilteringContainerViewProvider<E>, IIntervallContainerViewProvider<E>, IMappingContainerViewProvider<E>, IndexRequestable<E>, Iterable<E>, IterableWithCopyableIterator<E>, Mappable<E>, MaterializationRequestable, SingleSearchable<E>, StoringRequestable<E>, StringMappable
- All Known Subinterfaces:
IArrayList<E>, ILinkedList<E>, IMatrix<E>, IMatrixColumn<E>, IMatrixRow<E>, ISqlRecord
- All Known Implementing Classes:
AbstractContainer, AbstractExtendedContainer, ArrayContainerView, ArrayList, ContainerView, FilterContainerView, ImmutableList, IntervallContainerView, IterableContainerView, LinkedList, MappingContainerView, Matrix, MatrixColumn, MatrixRow, MultiContainerView, SingleContainer, SqlRecord
public interface IContainer<E>
extends AggregationRequestable<E>, ArrayMappable<E>, CountRequestable<E>, EmptinessRequestable, Filterable<E>, Groupable<E>, IFilteringContainerViewProvider<E>, IIntervallContainerViewProvider<E>, IMappingContainerViewProvider<E>, IndexRequestable<E>, IterableWithCopyableIterator<E>, Mappable<E>, MaterializationRequestable, SingleSearchable<E>, StoringRequestable<E>, StringMappable
A
IContainer can store several elements of a certain type. A
IContainer stores its element in a linear order. There can exists
additional orders. A IContainer is iterable.- Author:
- Silvan Wyss
-
Method Summary
Modifier and TypeMethodDescription<C extends Comparable<C>>
IContainer<E> toOrderedList(Function<E, C> comparableMapper) Methods inherited from interface AggregationRequestable
getAverage, getAverageOrZero, getMax, getMaxOrZero, getMedian, getMedianOrZero, getMin, getMinOrZero, getStandardDeviation, getSum, getSumOfInts, getVarianceMethods inherited from interface ArrayMappable
toArray, toByteArray, toCharArray, toDoubleArray, toIntArray, toLongArray, toStringArrayMethods inherited from interface CountRequestable
getCount, getCount, getCountOfMethods inherited from interface EmptinessRequestable
containsAny, isEmptyMethods inherited from interface Filterable
getStoredOfType, getStoredOthers, getStoredSelectedMethods inherited from interface Groupable
getStoredInGroupsMethods inherited from interface IFilteringContainerViewProvider
getViewOfStoredSelectedMethods inherited from interface IIntervallContainerViewProvider
getViewFromOneBasedStartIndex, getViewFromOneBasedStartIndexToOneBasedEndIndex, getViewToOneBasedEndIndex, getViewWithoutFirst, getViewWithoutFirst, getViewWithoutLast, getViewWithoutLastMethods inherited from interface IMappingContainerViewProvider
getViewOfMethods inherited from interface IndexRequestable
getOneBasedIndexOfFirst, getOneBasedIndexOfFirstEqualElement, getOneBasedIndexOfFirstOccurrenceOfMethods inherited from interface Iterable
forEach, spliteratorMethods inherited from interface IterableWithCopyableIterator
iteratorMethods inherited from interface Mappable
to, toMultiples, toNumbers, toStrings, toWithOneBasedIndexMethods inherited from interface MaterializationRequestable
isMaterialized, isViewMethods inherited from interface SingleSearchable
getOptionalStoredFirst, getOptionalStoredFirst, getStoredAtOneBasedIndex, getStoredByMax, getStoredByMin, getStoredFirst, getStoredFirst, getStoredFirstOfType, getStoredLast, getStoredOne, getStoredOneMethods inherited from interface StoringRequestable
contains, containsAllOf, containsAllOf, containsAny, containsAnyOf, containsAnyOf, containsAsManyAs, containsEqualing, containsExactlyEqualingInSameOrder, containsExactlyInSameOrder, containsLessThan, containsMoreThan, containsNone, containsNoneOf, containsNoneOf, containsOnce, containsOne, containsOne, containsOneEqualing, containsOnlyMethods inherited from interface StringMappable
toConcatenatedString, toStringWithSeparator, toStringWithSeparator
-
Method Details
-
toOrderedList
- Type Parameters:
C- is the type of theComparables the given comparableMapper returns.- Parameters:
comparableMapper-- Returns:
- a new
IContainerwith the elements of the currentIContainerordered from the smallest to the biggest element according to theComparables the given comparableMapper maps from the elements of the currentIContainer. - Throws:
RuntimeException- if the given comparableMapper is null.RuntimeException- if one of the elements of the currentIContaineris null.
-
toReversedList
IContainer<E> toReversedList()- Returns:
- a new
IContainerwith the elements of the currentIContainerin reversed order.
-