Package com.browseengine.bobo.geosearch

Examples of com.browseengine.bobo.geosearch.IGeoConverter


    private final Comparator<CartesianGeoRecord> geoComparator = new CartesianGeoRecordComparator();
   
    @Override
    //TODO:  Handle more frequent checkAborts
    public void merge(IGeoMergeInfo geoMergeInfo, GeoSearchConfig config) throws IOException {
        IGeoConverter geoConverter = config.getGeoConverter();
        int bufferSizePerGeoReader = config.getBufferSizePerGeoSegmentReader();
       
        Directory directory = geoMergeInfo.getDirectory();
        List<SegmentReader> readers = geoMergeInfo.getReaders();
        List<SegmentInfo> segments =  geoMergeInfo.getSegmentsToMerge();
View Full Code Here


    private void buildMergedSegment(List<BTree<CartesianGeoRecord>> mergeInputBTrees,
            List<BitVector> deletedDocsList, int newSegmentSize,
            IGeoMergeInfo geoMergeInfo, GeoSearchConfig config,
            IFieldNameFilterConverter fieldNameFilterConverter) throws IOException {
        Directory directory = geoMergeInfo.getDirectory();
        IGeoConverter geoConverter = config.getGeoConverter();
       
        String segmentName = geoMergeInfo.getNewSegment().name;
        String outputFileName = config.getGeoFileName(segmentName);
       
        GeoSegmentInfo geoSegmentInfo = buildGeoSegmentInfo(segmentName, fieldNameFilterConverter);
View Full Code Here

            throw new IllegalArgumentException("invalid uuid length: " + uuid.length
                    + ".  Expected uuid to be of length "
                    + config.getBytesForId() + ".");
        }
       
        IGeoConverter converter = config.getGeoConverter();
       
        GeoCoordinate geoCoordinate = field.getGeoCoordinate();
        IDGeoRecord geoRecord = converter.toIDGeoRecord(
                geoCoordinate.getLatitude(), geoCoordinate.getLongitude(), uuid);
        newRecords.add(geoRecord);
    }
View Full Code Here

                config.getBufferSizePerGeoSegmentReader(), geoRecordSerializer,
                geoComparator);
    }
   
    private GeoSegmentInfo buildGeoSegmentInfo(String segmentName) throws IOException {
        IGeoConverter converter = config.getGeoConverter();
       
        //write version
        GeoSegmentInfo info = new GeoSegmentInfo();
        info.setGeoVersion(GeoVersion.CURRENT_GEOONLY_VERSION);

        info.setSegmentName(segmentName);
       
        info.setBytesPerRecord(IDGeoRecordSerializer.INTERLACE_BYTES + config.getBytesForId());
       
        //now write field -> filterByte mapping info
        IFieldNameFilterConverter fieldNameFilterConverter = converter.makeFieldNameFilterConverter();
        if (fieldNameFilterConverter != null) {
            info.setFieldNameFilterConverter(fieldNameFilterConverter);
        }
       
        return info;
View Full Code Here

TOP

Related Classes of com.browseengine.bobo.geosearch.IGeoConverter

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.