diff --git a/google-cloud-core/src/main/java/com/google/cloud/BaseWriteChannel.java b/google-cloud-core/src/main/java/com/google/cloud/BaseWriteChannel.java index aaef34149f69..4d01a60e4422 100644 --- a/google-cloud-core/src/main/java/com/google/cloud/BaseWriteChannel.java +++ b/google-cloud-core/src/main/java/com/google/cloud/BaseWriteChannel.java @@ -41,7 +41,7 @@ public abstract class BaseWriteChannel< private final ServiceOptionsT options; private final EntityT entity; private final String uploadId; - private int position; + private long position; private byte[] buffer = new byte[0]; private int limit; private boolean isOpen = true; @@ -101,11 +101,11 @@ protected String getUploadId() { } @Deprecated - protected int position() { + protected long position() { return getPosition(); } - protected int getPosition() { + protected long getPosition() { return position; } @@ -119,7 +119,7 @@ protected byte[] getBuffer() { } @Deprecated - protected int limit() { + protected long limit() { return getLimit(); } @@ -245,7 +245,7 @@ protected abstract static class BaseState< protected final ServiceOptionsT serviceOptions; protected final EntityT entity; protected final String uploadId; - protected final int position; + protected final long position; protected final byte[] buffer; protected final boolean isOpen; protected final int chunkSize; @@ -274,7 +274,7 @@ public abstract static class Builder< private final ServiceOptionsT serviceOptions; private final EntityT entity; private final String uploadId; - private int position; + private long position; private byte[] buffer; private boolean isOpen; private int chunkSize; @@ -290,7 +290,7 @@ public Builder position(int position) { return setPosition(position); } - public Builder setPosition(int position) { + public Builder setPosition(long position) { this.position = position; return this; }