Package microsim.statistics.functions
Class SumArrayFunction
java.lang.Object
microsim.statistics.functions.AbstractFunction
microsim.statistics.functions.AbstractArrayFunction
microsim.statistics.functions.SumArrayFunction
- All Implemented Interfaces:
EventListener
,DoubleSource
,UpdatableSource
- Direct Known Subclasses:
SumArrayFunction.Double
,SumArrayFunction.Integer
,SumArrayFunction.Long
This class computes the sum of an array of source values. According to the source data type there are three data-type
oriented implementations. Each of them implements always the
DoubleSource
interface.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
SumFunction operating on double source values.static class
SumFunction operating on integer source values.static class
SumFunction operating on long source values.Nested classes/interfaces inherited from interface microsim.statistics.DoubleSource
DoubleSource.Variables
-
Field Summary
Fields inherited from class microsim.statistics.functions.AbstractArrayFunction
dblSource, intSource, lngSource, type, TYPE_DBL, TYPE_INT, TYPE_LNG
Fields inherited from class microsim.statistics.functions.AbstractFunction
timeChecker
-
Constructor Summary
ConstructorDescriptionSumArrayFunction
(@NonNull DoubleArraySource source) Create a sum function on a double array source.SumArrayFunction
(@NonNull IntArraySource source) Creates a sum function on an integer array source.SumArrayFunction
(@NonNull LongArraySource source) Creates a sum function on a long array source. -
Method Summary
Methods inherited from class microsim.statistics.functions.AbstractArrayFunction
apply, apply, apply, applyFunction
Methods inherited from class microsim.statistics.functions.AbstractFunction
isCheckingTime, onEvent, setCheckingTime, updateSource
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface microsim.statistics.DoubleSource
getDoubleValue
-
Constructor Details
-
SumArrayFunction
Creates a sum function on an integer array source.- Parameters:
source
- The data source.- Throws:
NullPointerException
- whensource
isnull
.
-
SumArrayFunction
Creates a sum function on a long array source.- Parameters:
source
- The data source.- Throws:
NullPointerException
- whensource
isnull
.
-
SumArrayFunction
Create a sum function on a double array source.- Parameters:
source
- The data source.- Throws:
NullPointerException
- whensource
isnull
.
-