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 RecursivePrefixTreeStrategyDistranceCustomScoreProvider(IndexReader reader, RecursivePrefixTreeStrategy strategy, PointPrefixTreeFieldCacheProvider cacheProvider, Point origin) : base(reader) { var ctx = strategy.GetSpatialContext(); _originPt = origin; _calculator = ctx.GetDistCalc(); _nullValue = (ctx.IsGeo() ? 180 : float.MaxValue); _cache = cacheProvider.GetCache(reader); }
public CachedDistanceDocValues(ShapeFieldCache<Point> cache, ShapeFieldCacheDistanceValueSource enclosingInstance) { this.enclosingInstance = enclosingInstance; this.cache = cache; }