Class GeoPointChecker


  • public class GeoPointChecker
    extends Object
    Provides checks for GeoPoint.
    • Constructor Detail

      • GeoPointChecker

        public GeoPointChecker()
    • Method Detail

      • checkLatitude

        public static double checkLatitude​(double latitude)
        Checks whether a GeoPoint latitude is valid. The value must be between -90.0 and 90.0 degrees.
        Parameters:
        latitude - the latitude to check
        Returns:
        the checked latitude
        Throws:
        IllegalArgumentException - if the latitude is out of range
      • checkLongitude

        public static double checkLongitude​(double longitude)
        Checks whether a GeoPoint longitude is valid. The value must be between -180.0 and 180.0 degrees.
        Parameters:
        longitude - the longitude to check
        Returns:
        the checked longitude
        Throws:
        IllegalArgumentException - if the longitude is out of range
      • checkValid

        public static com.google.apphosting.api.search.DocumentPb.FieldValue.Geo checkValid​(com.google.apphosting.api.search.DocumentPb.FieldValue.Geo geoPb)