implements
// @@protoc_insertion_point(builder_implements:build.bazel.remote.execution.v2.GetTreeRequest)
build.bazel.remote.execution.v2.GetTreeRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return build.bazel.remote.execution.v2.RemoteExecutionProto.internal_static_build_bazel_remote_execution_v2_GetTreeRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return build.bazel.remote.execution.v2.RemoteExecutionProto.internal_static_build_bazel_remote_execution_v2_GetTreeRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
build.bazel.remote.execution.v2.GetTreeRequest.class, build.bazel.remote.execution.v2.GetTreeRequest.Builder.class);
}
// Construct using build.bazel.remote.execution.v2.GetTreeRequest.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getRootDigestFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
instanceName_ = "";
rootDigest_ = null;
if (rootDigestBuilder_ != null) {
rootDigestBuilder_.dispose();
rootDigestBuilder_ = null;
}
pageSize_ = 0;
pageToken_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return build.bazel.remote.execution.v2.RemoteExecutionProto.internal_static_build_bazel_remote_execution_v2_GetTreeRequest_descriptor;
}
@java.lang.Override
public build.bazel.remote.execution.v2.GetTreeRequest getDefaultInstanceForType() {
return build.bazel.remote.execution.v2.GetTreeRequest.getDefaultInstance();
}
@java.lang.Override
public build.bazel.remote.execution.v2.GetTreeRequest build() {
build.bazel.remote.execution.v2.GetTreeRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public build.bazel.remote.execution.v2.GetTreeRequest buildPartial() {
build.bazel.remote.execution.v2.GetTreeRequest result = new build.bazel.remote.execution.v2.GetTreeRequest(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(build.bazel.remote.execution.v2.GetTreeRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.instanceName_ = instanceName_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000002) != 0)) {
result.rootDigest_ = rootDigestBuilder_ == null
? rootDigest_
: rootDigestBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.pageSize_ = pageSize_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.pageToken_ = pageToken_;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof build.bazel.remote.execution.v2.GetTreeRequest) {
return mergeFrom((build.bazel.remote.execution.v2.GetTreeRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(build.bazel.remote.execution.v2.GetTreeRequest other) {
if (other == build.bazel.remote.execution.v2.GetTreeRequest.getDefaultInstance()) return this;
if (!other.getInstanceName().isEmpty()) {
instanceName_ = other.instanceName_;
bitField0_ |= 0x00000001;
onChanged();
}
if (other.hasRootDigest()) {
mergeRootDigest(other.getRootDigest());
}
if (other.getPageSize() != 0) {
setPageSize(other.getPageSize());
}
if (!other.getPageToken().isEmpty()) {
pageToken_ = other.pageToken_;
bitField0_ |= 0x00000008;
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
instanceName_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
input.readMessage(
getRootDigestFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 24: {
pageSize_ = input.readInt32();
bitField0_ |= 0x00000004;
break;
} // case 24
case 34: {
pageToken_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000008;
break;
} // case 34
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object instanceName_ = "";
/**
*
* The instance of the execution system to operate against. A server may
* support multiple instances of the execution system (with their own workers,
* storage, caches, etc.). The server MAY require use of this field to select
* between them in an implementation-defined fashion, otherwise it can be
* omitted.
*
*
* string instance_name = 1;
* @return The instanceName.
*/
public java.lang.String getInstanceName() {
java.lang.Object ref = instanceName_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
instanceName_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The instance of the execution system to operate against. A server may
* support multiple instances of the execution system (with their own workers,
* storage, caches, etc.). The server MAY require use of this field to select
* between them in an implementation-defined fashion, otherwise it can be
* omitted.
*
*
* string instance_name = 1;
* @return The bytes for instanceName.
*/
public com.google.protobuf.ByteString
getInstanceNameBytes() {
java.lang.Object ref = instanceName_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
instanceName_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The instance of the execution system to operate against. A server may
* support multiple instances of the execution system (with their own workers,
* storage, caches, etc.). The server MAY require use of this field to select
* between them in an implementation-defined fashion, otherwise it can be
* omitted.
*
*
* string instance_name = 1;
* @param value The instanceName to set.
* @return This builder for chaining.
*/
public Builder setInstanceName(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
instanceName_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* The instance of the execution system to operate against. A server may
* support multiple instances of the execution system (with their own workers,
* storage, caches, etc.). The server MAY require use of this field to select
* between them in an implementation-defined fashion, otherwise it can be
* omitted.
*
*
* string instance_name = 1;
* @return This builder for chaining.
*/
public Builder clearInstanceName() {
instanceName_ = getDefaultInstance().getInstanceName();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* The instance of the execution system to operate against. A server may
* support multiple instances of the execution system (with their own workers,
* storage, caches, etc.). The server MAY require use of this field to select
* between them in an implementation-defined fashion, otherwise it can be
* omitted.
*
*
* string instance_name = 1;
* @param value The bytes for instanceName to set.
* @return This builder for chaining.
*/
public Builder setInstanceNameBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
instanceName_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private build.bazel.remote.execution.v2.Digest rootDigest_;
private com.google.protobuf.SingleFieldBuilderV3<
build.bazel.remote.execution.v2.Digest, build.bazel.remote.execution.v2.Digest.Builder, build.bazel.remote.execution.v2.DigestOrBuilder> rootDigestBuilder_;
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
* @return Whether the rootDigest field is set.
*/
public boolean hasRootDigest() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
* @return The rootDigest.
*/
public build.bazel.remote.execution.v2.Digest getRootDigest() {
if (rootDigestBuilder_ == null) {
return rootDigest_ == null ? build.bazel.remote.execution.v2.Digest.getDefaultInstance() : rootDigest_;
} else {
return rootDigestBuilder_.getMessage();
}
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
public Builder setRootDigest(build.bazel.remote.execution.v2.Digest value) {
if (rootDigestBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
rootDigest_ = value;
} else {
rootDigestBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
public Builder setRootDigest(
build.bazel.remote.execution.v2.Digest.Builder builderForValue) {
if (rootDigestBuilder_ == null) {
rootDigest_ = builderForValue.build();
} else {
rootDigestBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
public Builder mergeRootDigest(build.bazel.remote.execution.v2.Digest value) {
if (rootDigestBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0) &&
rootDigest_ != null &&
rootDigest_ != build.bazel.remote.execution.v2.Digest.getDefaultInstance()) {
getRootDigestBuilder().mergeFrom(value);
} else {
rootDigest_ = value;
}
} else {
rootDigestBuilder_.mergeFrom(value);
}
if (rootDigest_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
public Builder clearRootDigest() {
bitField0_ = (bitField0_ & ~0x00000002);
rootDigest_ = null;
if (rootDigestBuilder_ != null) {
rootDigestBuilder_.dispose();
rootDigestBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
public build.bazel.remote.execution.v2.Digest.Builder getRootDigestBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getRootDigestFieldBuilder().getBuilder();
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
public build.bazel.remote.execution.v2.DigestOrBuilder getRootDigestOrBuilder() {
if (rootDigestBuilder_ != null) {
return rootDigestBuilder_.getMessageOrBuilder();
} else {
return rootDigest_ == null ?
build.bazel.remote.execution.v2.Digest.getDefaultInstance() : rootDigest_;
}
}
/**
*
* The digest of the root, which must be an encoded
* [Directory][build.bazel.remote.execution.v2.Directory] message
* stored in the
* [ContentAddressableStorage][build.bazel.remote.execution.v2.ContentAddressableStorage].
*
*
* .build.bazel.remote.execution.v2.Digest root_digest = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
build.bazel.remote.execution.v2.Digest, build.bazel.remote.execution.v2.Digest.Builder, build.bazel.remote.execution.v2.DigestOrBuilder>
getRootDigestFieldBuilder() {
if (rootDigestBuilder_ == null) {
rootDigestBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
build.bazel.remote.execution.v2.Digest, build.bazel.remote.execution.v2.Digest.Builder, build.bazel.remote.execution.v2.DigestOrBuilder>(
getRootDigest(),
getParentForChildren(),
isClean());
rootDigest_ = null;
}
return rootDigestBuilder_;
}
private int pageSize_ ;
/**
*
* A maximum page size to request. If present, the server will request no more
* than this many items. Regardless of whether a page size is specified, the
* server may place its own limit on the number of items to be returned and
* require the client to retrieve more items using a subsequent request.
*
*
* int32 page_size = 3;
* @return The pageSize.
*/
@java.lang.Override
public int getPageSize() {
return pageSize_;
}
/**
*
* A maximum page size to request. If present, the server will request no more
* than this many items. Regardless of whether a page size is specified, the
* server may place its own limit on the number of items to be returned and
* require the client to retrieve more items using a subsequent request.
*
*
* int32 page_size = 3;
* @param value The pageSize to set.
* @return This builder for chaining.
*/
public Builder setPageSize(int value) {
pageSize_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* A maximum page size to request. If present, the server will request no more
* than this many items. Regardless of whether a page size is specified, the
* server may place its own limit on the number of items to be returned and
* require the client to retrieve more items using a subsequent request.
*
*
* int32 page_size = 3;
* @return This builder for chaining.
*/
public Builder clearPageSize() {
bitField0_ = (bitField0_ & ~0x00000004);
pageSize_ = 0;
onChanged();
return this;
}
private java.lang.Object pageToken_ = "";
/**
*
* A page token, which must be a value received in a previous
* [GetTreeResponse][build.bazel.remote.execution.v2.GetTreeResponse].
* If present, the server will use that token as an offset, returning only
* that page and the ones that succeed it.
*
*
* string page_token = 4;
* @return The pageToken.
*/
public java.lang.String getPageToken() {
java.lang.Object ref = pageToken_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
pageToken_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* A page token, which must be a value received in a previous
* [GetTreeResponse][build.bazel.remote.execution.v2.GetTreeResponse].
* If present, the server will use that token as an offset, returning only
* that page and the ones that succeed it.
*
*
* string page_token = 4;
* @return The bytes for pageToken.
*/
public com.google.protobuf.ByteString
getPageTokenBytes() {
java.lang.Object ref = pageToken_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
pageToken_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* A page token, which must be a value received in a previous
* [GetTreeResponse][build.bazel.remote.execution.v2.GetTreeResponse].
* If present, the server will use that token as an offset, returning only
* that page and the ones that succeed it.
*
*
* string page_token = 4;
* @param value The pageToken to set.
* @return This builder for chaining.
*/
public Builder setPageToken(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
pageToken_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* A page token, which must be a value received in a previous
* [GetTreeResponse][build.bazel.remote.execution.v2.GetTreeResponse].
* If present, the server will use that token as an offset, returning only
* that page and the ones that succeed it.
*
*
* string page_token = 4;
* @return This builder for chaining.
*/
public Builder clearPageToken() {
pageToken_ = getDefaultInstance().getPageToken();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged();
return this;
}
/**
*
* A page token, which must be a value received in a previous
* [GetTreeResponse][build.bazel.remote.execution.v2.GetTreeResponse].
* If present, the server will use that token as an offset, returning only
* that page and the ones that succeed it.
*
*
* string page_token = 4;
* @param value The bytes for pageToken to set.
* @return This builder for chaining.
*/
public Builder setPageTokenBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
pageToken_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:build.bazel.remote.execution.v2.GetTreeRequest)
}
// @@protoc_insertion_point(class_scope:build.bazel.remote.execution.v2.GetTreeRequest)
private static final build.bazel.remote.execution.v2.GetTreeRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new build.bazel.remote.execution.v2.GetTreeRequest();
}
public static build.bazel.remote.execution.v2.GetTreeRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public GetTreeRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public build.bazel.remote.execution.v2.GetTreeRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}