Package org.ojalgo.random
Class SampleSet.CombineableSet<N extends java.lang.Comparable<N>>
- java.lang.Object
-
- org.ojalgo.random.SampleSet.CombineableSet<N>
-
- All Implemented Interfaces:
TwoStepMapper<N,SampleSet>
,TwoStepMapper.Combineable<N,SampleSet,SampleSet.CombineableSet<N>>
- Enclosing class:
- SampleSet
public static final class SampleSet.CombineableSet<N extends java.lang.Comparable<N>> extends java.lang.Object implements TwoStepMapper.Combineable<N,SampleSet,SampleSet.CombineableSet<N>>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.ojalgo.type.function.TwoStepMapper
TwoStepMapper.Combineable<T,R,A extends TwoStepMapper.Combineable<T,R,A>>, TwoStepMapper.KeyCounter<T,G>, TwoStepMapper.Mergeable<T,R>, TwoStepMapper.SimpleCache<K,V>
-
-
Field Summary
Fields Modifier and Type Field Description private NumberList.ListFactory<N>
myFactory
private NumberList<N>
myNumbers
-
Constructor Summary
Constructors Constructor Description CombineableSet(NumberList.ListFactory<N> factory)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
combine(SampleSet.CombineableSet<N> other)
This method can be used to combine the state of multiple instances.void
consume(double item)
void
consume(N item)
Input/consume the items that should be mapped(package private) NumberList<N>
getNumbers()
SampleSet
getResults()
Output the mapped resultsSampleSet.CombineableSet<N>
newInstance()
void
reset()
Reset, so it can be re-used
-
-
-
Field Detail
-
myFactory
private final NumberList.ListFactory<N extends java.lang.Comparable<N>> myFactory
-
myNumbers
private final NumberList<N extends java.lang.Comparable<N>> myNumbers
-
-
Constructor Detail
-
CombineableSet
CombineableSet(NumberList.ListFactory<N> factory)
-
-
Method Detail
-
combine
public void combine(SampleSet.CombineableSet<N> other)
Description copied from interface:TwoStepMapper.Combineable
This method can be used to combine the state of multiple instances. The intermediate/internal state from one instance is combined into another.- Specified by:
combine
in interfaceTwoStepMapper.Combineable<N extends java.lang.Comparable<N>,SampleSet,SampleSet.CombineableSet<N extends java.lang.Comparable<N>>>
-
consume
public void consume(double item)
-
consume
public void consume(N item)
Description copied from interface:TwoStepMapper
Input/consume the items that should be mapped- Specified by:
consume
in interfaceTwoStepMapper<N extends java.lang.Comparable<N>,SampleSet>
-
getResults
public SampleSet getResults()
Description copied from interface:TwoStepMapper
Output the mapped results- Specified by:
getResults
in interfaceTwoStepMapper<N extends java.lang.Comparable<N>,SampleSet>
-
newInstance
public SampleSet.CombineableSet<N> newInstance()
-
reset
public void reset()
Description copied from interface:TwoStepMapper
Reset, so it can be re-used- Specified by:
reset
in interfaceTwoStepMapper<N extends java.lang.Comparable<N>,SampleSet>
-
getNumbers
NumberList<N> getNumbers()
-
-