Code example for IOException

0
    public List<Address> getFromLocation(double latitude, double longitude, int maxResults) throws IOException {
        wasCalled = true;
        this.lastLatitude = latitude;
        this.lastLongitude = longitude;
        if (shouldSimulateGeocodeException) {
            throw new IOException("Simulated geocode exception");
        } 
        Address address = makeAddress();
        address.setAddressLine(0, addressLine1);
        address.setLocality(city);
        address.setAdminArea(state);
        address.setPostalCode(zip);
        address.setCountryCode(countryCode);
        return oneElementList(address);
    } 
 
    @Implementation 
    public List<Address> getFromLocationName(String locationName, int maxResults) throws IOException {
        didResolution = true;
        this.lastLocationName = locationName;
Connect your IDE to all the code out there  Get Codota for Java