Package com.google.common.geometry

Examples of com.google.common.geometry.S2Cell


    return null;
  }

  private static boolean containsGeodataToFind(S2CellId c, S2LatLngRect latLngRect) {
    if (latLngRect != null) {
      return latLngRect.intersects(new S2Cell(c));
    }

    return false;
  }
View Full Code Here


    }
  }

  public static long generateGeohash(GeoPoint geoPoint) {
    S2LatLng latLng = S2LatLng.fromDegrees(geoPoint.getLatitude(), geoPoint.getLongitude());
    S2Cell cell = new S2Cell(latLng);
    S2CellId cellId = cell.id();

    return cellId.id();
  }
View Full Code Here

TOP

Related Classes of com.google.common.geometry.S2Cell

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.