Module ojalgo
Package org.ojalgo.array
Class NumberList.ListFactory<N extends java.lang.Comparable<N>>
- java.lang.Object
-
- org.ojalgo.array.NumberList.ListFactory<N>
-
- Enclosing class:
- NumberList<N extends java.lang.Comparable<N>>
public static final class NumberList.ListFactory<N extends java.lang.Comparable<N>> extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description private DenseArray.Factory<N,?>myDenseFactoryprivate GrowthStrategymyGrowthStrategy
-
Constructor Summary
Constructors Constructor Description ListFactory(DenseArray.Factory<N,?> denseFactory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description NumberList.ListFactory<N>chunk(long chunk)NumberList.ListFactory<N>initial(long initial)NumberList<N>make()NumberList.ListFactory<N>segment(long segment)With very large data structures, particularly sparse ones, the underlying (dense) storage is segmented.
-
-
-
Field Detail
-
myGrowthStrategy
private GrowthStrategy myGrowthStrategy
-
myDenseFactory
private final DenseArray.Factory<N extends java.lang.Comparable<N>,?> myDenseFactory
-
-
Constructor Detail
-
ListFactory
ListFactory(DenseArray.Factory<N,?> denseFactory)
-
-
Method Detail
-
chunk
public NumberList.ListFactory<N> chunk(long chunk)
- Parameters:
chunk- Defines a capacity break point. Below this point the capacity is doubled when needed. Above it, it is grown by adding one "chunk" at the time. Must be a power of 2. (The builder will enforce that for you.)- Returns:
- this
-
initial
public NumberList.ListFactory<N> initial(long initial)
- Parameters:
initial- Sets the initial capacity of the "arrays" to be created using this factory.- Returns:
- this
-
make
public NumberList<N> make()
-
segment
public NumberList.ListFactory<N> segment(long segment)
With very large data structures, particularly sparse ones, the underlying (dense) storage is segmented. (Very large arrays are implemented as an array of arrays.) This determines the size/length of one such segment. Must be a multiple of the chunk size as well as a power of 2. (The builder will enforce this for you.)
-
-