Class DurationBetween
java.lang.Object
trade.invision.indicators.indicators.Indicator<Num>
trade.invision.indicators.indicators.instant.DurationBetween
DurationBetween is a Num Indicator to provide the Duration between two
Instants in the given ChronoUnit. A positive value will be returned if second is after
first. A negative value will be returned if second is before first.-
Nested Class Summary
Nested classes/interfaces inherited from class trade.invision.indicators.indicators.Indicator
Indicator.CacheSeries -
Field Summary
Fields inherited from class trade.invision.indicators.indicators.Indicator
cachedAddCallCount, cachedIndex, cachedValue, cacheSeries, minimumStableIndex, series -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedDurationBetween(Indicator<Instant> first, Indicator<Instant> second, ChronoUnit unit) -
Method Summary
Modifier and TypeMethodDescriptionprotected Numcalculate(long index) Performs the calculation of thisIndicatorat the givenindex.static DurationBetweendurationBetween(Indicator<Instant> first, Indicator<Instant> second, ChronoUnit unit) Gets aDurationBetween.Methods inherited from class trade.invision.indicators.indicators.Indicator
caching, getMinimumStableIndex, getSeries, getValue, isCaching, numOf, numOf, numOf, numOf, numOfEight, numOfFive, numOfFour, numOfHalf, numOfHundred, numOfHundredth, numOfNegativeOne, numOfNine, numOfOne, numOfSeven, numOfSix, numOfTen, numOfTenth, numOfThousand, numOfThousandth, numOfThree, numOfTwo, numOfZero, purgeCache
-
Constructor Details
-
DurationBetween
-
-
Method Details
-
durationBetween
public static DurationBetween durationBetween(Indicator<Instant> first, Indicator<Instant> second, ChronoUnit unit) Gets aDurationBetween.- Parameters:
first- the firstIndicatorsecond- the secondIndicatorunit- theChronoUnit
-
calculate
Description copied from class:IndicatorPerforms the calculation of thisIndicatorat the givenindex.
-