public UploadParser onRequestComplete(@Nonnull OnRequestComplete requestCallback) {
this.requestCallback = requireNonNull(requestCallback);
return this;
}
public UploadParser onError(@Nonnull OnError errorCallback) {
<BUG>this.errorCallback = requireNonNull(errorCallback);
return this;</BUG>
}
public UploadParser sizeThreshold(@Nonnegative int sizeThreshold) {
this.sizeThreshold = Math.max(sizeThreshold, 0);

public UploadParser onRequestComplete(@Nonnull OnRequestComplete requestCallback) {
this.requestCallback = requireNonNull(requestCallback);
return this;
}
public UploadParser onError(@Nonnull OnError errorCallback) {
this.errorCallback = requireNonNull(errorCallback);
return this;
}
public UploadParser withResponse(@Nonnull UploadResponse uploadResponse) {
this.uploadResponse = uploadResponse;
return this;
}
public UploadParser sizeThreshold(@Nonnegative int sizeThreshold) {
this.sizeThreshold = Math.max(sizeThreshold, 0);
