Package org.apache.lucene.index

Examples of org.apache.lucene.index.SegmentReader$CoreReaders


        throw new IllegalStateException("reader not insance of " + SegmentReader.class);
      }

      try {
        if (_readerMap != null && !_readerMap.isEmpty()) {
          SegmentReader sr = (SegmentReader) reader;
          String segmentName = sr.getSegmentName();
          ZoieSegmentReader<R> zoieSegmentReader = _readerMap.get(segmentName);
          if (zoieSegmentReader != null && zoieSegmentReader.getInnerReader() == sr) {
            return new ZoieSegmentReader<R>(zoieSegmentReader, sr);
          }
        }
View Full Code Here


        }
        return t;
    }

    private static long getReaderRamBytesUsed(LeafReaderContext reader) {
        final SegmentReader segmentReader = SegmentReaderUtils.segmentReader(reader.reader());
        return segmentReader.ramBytesUsed();
    }
View Full Code Here

   
    private List<GeoSegmentReader<CartesianGeoRecord>> buildGeoSegmentReaders(GeoSearchConfig geoSearchConfig) throws IOException {
        geoSegmentReaders = new ArrayList<GeoSegmentReader<CartesianGeoRecord>>();
        if (subGeoReaders == null || subGeoReaders.size() == 0) {
            if (in instanceof SegmentReader) {
                SegmentReader segmentReader = (SegmentReader) in;
                int maxDoc = segmentReader.maxDoc();
                String segmentName = segmentReader.getSegmentName();
                String geoSegmentName = geoSearchConfig.getGeoFileName(segmentName);
                GeoSegmentReader<CartesianGeoRecord> geoSegmentReader = new GeoSegmentReader<CartesianGeoRecord>(
                        directory(), geoSegmentName, maxDoc, DEFAULT_BUFFER_SIZE_PER_SEGMENT,
                        geoRecordSerializer, geoRecordComparator);
                geoSegmentReaders.add(geoSegmentReader);
View Full Code Here

TOP

Related Classes of org.apache.lucene.index.SegmentReader$CoreReaders

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.