code: public static DirectionsRefreshResponse fromJson(String json) {
      GsonBuilder gsonBuilder = new GsonBuilder();
      gsonBuilder.registerTypeAdapterFactory(DirectionsRefreshAdapterFactory.create())
        .registerTypeAdapterFactory(DirectionsAdapterFactory.create());
      return gsonBuilder.create().fromJson(json, DirectionsRefreshResponse.class);
    }
docs: Create a new instance of this class by passing in a formatted valid JSON String.
  
  @param json a formatted valid JSON string defining a Directions Refresh response
  @return a new instance of this class defined by the values passed inside this static factory
  method
  @since 4.4.0