Package mil.nga.giat.geowave.index.sfc

Examples of mil.nga.giat.geowave.index.sfc.SpaceFillingCurve


      new SFCDimensionDefinition(
          new LongitudeDefinition(),
          LONGITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);
    Assert.assertEquals(
        expectedID,
        ByteBuffer.wrap(
            hilbertSFC.getId(testValues)).getLong());

  }
View Full Code Here


      new SFCDimensionDefinition(
          new LongitudeDefinition(),
          LONGITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);

    Assert.assertEquals(
        expectedID,
        ByteBuffer.wrap(
            hilbertSFC.getId(testValues)).getLong());

  }
View Full Code Here

      new SFCDimensionDefinition(
          new LongitudeDefinition(),
          LONGITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);
    Assert.assertEquals(
        expectedID,
        ByteBuffer.wrap(
            hilbertSFC.getId(testValues)).getLong());

  }
View Full Code Here

      new SFCDimensionDefinition(
          new LongitudeDefinition(),
          LONGITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);

    Assert.assertTrue(SignedBytes.lexicographicalComparator().compare(
        hilbertSFC.getId(minValue),
        hilbertSFC.getId(maxValue)) < 0);

  }
View Full Code Here

      new SFCDimensionDefinition(
          new LongitudeDefinition(),
          LONGITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);

    Assert.assertEquals(
        expectedID,
        ByteBuffer.wrap(
            hilbertSFC.getId(testValues)).getLong());

  }
View Full Code Here

      new SFCDimensionDefinition(
          new LatitudeDefinition(),
          LATITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);

    // Create a IndexRange object using the x axis
    final NumericRange rangeX = new NumericRange(
        55,
        57);

    // Create a IndexRange object using the y axis
    final NumericRange rangeY = new NumericRange(
        25,
        27);
    BasicNumericDataset spatialQuery = new BasicNumericDataset(
        new NumericData[] {
          rangeX,
          rangeY
        });

    RangeDecomposition rangeDecomposition = hilbertSFC.decomposeQuery(
        spatialQuery,
        1);

    Assert.assertEquals(
        1,
View Full Code Here

      new SFCDimensionDefinition(
          new LatitudeDefinition(),
          LATITUDE_BITS)
    };

    SpaceFillingCurve hilbertSFC = SFCFactory.createSpaceFillingCurve(
        SPATIAL_DIMENSIONS,
        SFCType.HILBERT);
    // Create a IndexRange object using the x axis
    final NumericRange rangeX = new NumericRange(
        10,
        57);

    // Create a IndexRange object using the y axis
    final NumericRange rangeY = new NumericRange(
        25,
        50);
    BasicNumericDataset spatialQuery = new BasicNumericDataset(
        new NumericData[] {
          rangeX,
          rangeY
        });

    RangeDecomposition rangeDecomposition = hilbertSFC.decomposeQuery(
        spatialQuery,
        20);

    Assert.assertEquals(
        20,
View Full Code Here

    final List<ByteArrayRange> queryRanges = new ArrayList<ByteArrayRange>();
    final BinnedNumericDataset[] binnedQueries = BinnedNumericDataset.applyBins(
        indexedRange,
        baseDefinitions);
    for (int tier = orderedSfcs.length - 1; tier >= 0; tier--) {
      final SpaceFillingCurve sfc = orderedSfcs[tier];
      queryRanges.addAll(getQueryRanges(
          binnedQueries,
          sfc,
          maxRangeDecomposition,
          (byte) tier));
View Full Code Here

    // precision tier does not have a single SFC value for this data, it
    // will be multiple row IDs

    // what tier does this entry belong in?
    for (int tier = orderedSfcs.length - 1; tier >= 0; tier--) {
      final SpaceFillingCurve sfc = orderedSfcs[tier];
      // loop through space filling curves and stop when both the min and
      // max of the ranges fit the same row ID
      final List<ByteArrayId> rowIdsAtTier = getRowIdsAtTier(
          index,
          tier,
View Full Code Here

TOP

Related Classes of mil.nga.giat.geowave.index.sfc.SpaceFillingCurve

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.