code: public <T> Observable<ServiceResponse<T>> getPutOrPatchResultAsync(Observable<Response<ResponseBody>> observable, final Type resourceType) {
          return this.<T>beginPutOrPatchAsync(observable, resourceType)
                  .toObservable()
                  .flatMap(new Func1<PollingState<T>, Observable<PollingState<T>>>() {
                      @Override
                      public Observable<PollingState<T>> call(PollingState<T> pollingState) {
                          return pollPutOrPatchAsync(pollingState, resourceType);
                      }
                  })
                  .last()
                  .map(new Func1<PollingState<T>, ServiceResponse<T>>() {
                      @Override
                      public ServiceResponse<T> call(PollingState<T> pollingState) {
                          return new ServiceResponse<>(pollingState.resource(), pollingState.response());
                      }
                  });
      }
docs: Handles an initial response from a PUT or PATCH operation response by polling the status of the operation
  asynchronously, once the operation finishes emits the final response.
  
  @param observable the initial observable from the PUT or PATCH operation.
  @param resourceType the java.lang.reflect.Type of the resource.
  @param <T>       the return type of the caller.
  @return          the observable of which a subscription will lead to a final response.