Package uk.ac.starlink.ttools.plot2
Class RangeCollector<S extends uk.ac.starlink.util.Splittable<S>>
- java.lang.Object
-
- uk.ac.starlink.ttools.plot2.RangeCollector<S>
-
- All Implemented Interfaces:
uk.ac.starlink.util.SplitCollector<S,Range[]>
public abstract class RangeCollector<S extends uk.ac.starlink.util.Splittable<S>> extends java.lang.Object implements uk.ac.starlink.util.SplitCollector<S,Range[]>
Partial SplitCollector implementation for accumulating range data. Theaccumulate
method should be implemented to submit values to an N-element array of ranges.On completion, the
mergeRanges(uk.ac.starlink.ttools.plot.Range[], uk.ac.starlink.ttools.plot.Range[])
method may be used to update a supplied Range array with the collected result.- Since:
- 22 Jan 2021
- Author:
- Mark Taylor
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
RangeCollector(int ndim)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Range[]
combine(Range[] ranges1, Range[] ranges2)
Range[]
createAccumulator()
void
mergeRanges(Range[] ranges0, Range[] ranges1)
Merges the content of the second range into the first one.
-