public CachedDistanceFunctionValue(AtomicReader reader, ShapeFieldCacheDistanceValueSource enclosingInstance) { cache = enclosingInstance.provider.GetCache(reader); this.enclosingInstance = enclosingInstance; from = enclosingInstance.from; calculator = enclosingInstance.ctx.GetDistCalc(); nullValue = (enclosingInstance.ctx.IsGeo() ? 180 : double.MaxValue); }
public CachedDistanceDocValues(IndexReader reader, ShapeFieldCacheDistanceValueSource enclosingInstance) { cache = enclosingInstance.provider.GetCache(reader); this.enclosingInstance = enclosingInstance; from = enclosingInstance.from; calculator = enclosingInstance.ctx.GetDistCalc(); nullValue = (enclosingInstance.ctx.IsGeo() ? 180 : double.MaxValue); }
public CachedDistanceFunctionValue(AtomicReader reader, ShapeFieldCacheDistanceValueSource enclosingInstance) { cache = enclosingInstance.provider.GetCache(reader); this.enclosingInstance = enclosingInstance; from = enclosingInstance.from; calculator = enclosingInstance.ctx.DistCalc; nullValue = (enclosingInstance.ctx.IsGeo ? 180 * enclosingInstance.multiplier : double.MaxValue); }
public CachedDistanceFunctionValue(ShapeFieldCacheDistanceValueSource outerInstance, AtomicReader reader) { // LUCENENET specific - added guard clauses this.outerInstance = outerInstance ?? throw new ArgumentNullException(nameof(outerInstance)); if (reader is null) { throw new ArgumentNullException(nameof(reader)); } cache = outerInstance.provider.GetCache(reader); from = outerInstance.from; calculator = outerInstance.ctx.DistanceCalculator; nullValue = (outerInstance.ctx.IsGeo ? 180 * outerInstance.multiplier : double.MaxValue); }
public CachedDistanceDocValues(ShapeFieldCache<Point> cache, ShapeFieldCacheDistanceValueSource enclosingInstance) { this.enclosingInstance = enclosingInstance; this.cache = cache; }