code: public static Double checkLatitude(String name, Double latitude) {
          if (latitude == null) {
              throw new IndexException("{} required", name);
          } else if (latitude < MIN_LATITUDE || latitude > MAX_LATITUDE) {
              throw new IndexException("{} must be in range [{}, {}], but found {}",
                                       name,
                                       MIN_LATITUDE,
                                       MAX_LATITUDE,
                                       latitude);
          }
          return latitude;
      }
docs: Checks if the specified latitude is correct.
  
  @param name the name of the latitude field
  @param latitude the value of the latitude field
  @return the latitude