@Override
    public ApiException getError() {
      if (successful()) {
        return null;
      }
      return ApiException.from(status, errorMessage);
    }
Retrieves the elevations of an encoded polyline path.

@param context The {@link GeoApiContext} to make requests through.
@param encodedPolyline The encoded polyline to retrieve elevations for.
@return The elevations as a {@link PendingResult}.
src/main/java/com/google/maps/ElevationApi.java