com.google.cloud.retail.v2beta.ImportMetadata Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of proto-google-cloud-retail-v2beta Show documentation
Show all versions of proto-google-cloud-retail-v2beta Show documentation
Proto library for google-cloud-retail
/*
* Copyright 2024 Google LLC
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/cloud/retail/v2beta/import_config.proto
// Protobuf Java Version: 3.25.3
package com.google.cloud.retail.v2beta;
/**
*
*
*
* Metadata related to the progress of the Import operation. This is
* returned by the google.longrunning.Operation.metadata field.
*
*
* Protobuf type {@code google.cloud.retail.v2beta.ImportMetadata}
*/
public final class ImportMetadata extends com.google.protobuf.GeneratedMessageV3
implements
// @@protoc_insertion_point(message_implements:google.cloud.retail.v2beta.ImportMetadata)
ImportMetadataOrBuilder {
private static final long serialVersionUID = 0L;
// Use ImportMetadata.newBuilder() to construct.
private ImportMetadata(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ImportMetadata() {
requestId_ = "";
notificationPubsubTopic_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
return new ImportMetadata();
}
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
return com.google.cloud.retail.v2beta.ImportConfigProto
.internal_static_google_cloud_retail_v2beta_ImportMetadata_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.cloud.retail.v2beta.ImportConfigProto
.internal_static_google_cloud_retail_v2beta_ImportMetadata_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.cloud.retail.v2beta.ImportMetadata.class,
com.google.cloud.retail.v2beta.ImportMetadata.Builder.class);
}
private int bitField0_;
public static final int CREATE_TIME_FIELD_NUMBER = 1;
private com.google.protobuf.Timestamp createTime_;
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*
* @return Whether the createTime field is set.
*/
@java.lang.Override
public boolean hasCreateTime() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*
* @return The createTime.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getCreateTime() {
return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_;
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() {
return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_;
}
public static final int UPDATE_TIME_FIELD_NUMBER = 2;
private com.google.protobuf.Timestamp updateTime_;
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*
* @return Whether the updateTime field is set.
*/
@java.lang.Override
public boolean hasUpdateTime() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*
* @return The updateTime.
*/
@java.lang.Override
public com.google.protobuf.Timestamp getUpdateTime() {
return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_;
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
@java.lang.Override
public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_;
}
public static final int SUCCESS_COUNT_FIELD_NUMBER = 3;
private long successCount_ = 0L;
/**
*
*
*
* Count of entries that were processed successfully.
*
*
* int64 success_count = 3;
*
* @return The successCount.
*/
@java.lang.Override
public long getSuccessCount() {
return successCount_;
}
public static final int FAILURE_COUNT_FIELD_NUMBER = 4;
private long failureCount_ = 0L;
/**
*
*
*
* Count of entries that encountered errors while processing.
*
*
* int64 failure_count = 4;
*
* @return The failureCount.
*/
@java.lang.Override
public long getFailureCount() {
return failureCount_;
}
public static final int REQUEST_ID_FIELD_NUMBER = 5;
@SuppressWarnings("serial")
private volatile java.lang.Object requestId_ = "";
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @return The requestId.
*/
@java.lang.Override
@java.lang.Deprecated
public java.lang.String getRequestId() {
java.lang.Object ref = requestId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
requestId_ = s;
return s;
}
}
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @return The bytes for requestId.
*/
@java.lang.Override
@java.lang.Deprecated
public com.google.protobuf.ByteString getRequestIdBytes() {
java.lang.Object ref = requestId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
requestId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int NOTIFICATION_PUBSUB_TOPIC_FIELD_NUMBER = 6;
@SuppressWarnings("serial")
private volatile java.lang.Object notificationPubsubTopic_ = "";
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @return The notificationPubsubTopic.
*/
@java.lang.Override
public java.lang.String getNotificationPubsubTopic() {
java.lang.Object ref = notificationPubsubTopic_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
notificationPubsubTopic_ = s;
return s;
}
}
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @return The bytes for notificationPubsubTopic.
*/
@java.lang.Override
public com.google.protobuf.ByteString getNotificationPubsubTopicBytes() {
java.lang.Object ref = notificationPubsubTopic_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
notificationPubsubTopic_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(1, getCreateTime());
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(2, getUpdateTime());
}
if (successCount_ != 0L) {
output.writeInt64(3, successCount_);
}
if (failureCount_ != 0L) {
output.writeInt64(4, failureCount_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(requestId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 5, requestId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(notificationPubsubTopic_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 6, notificationPubsubTopic_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getCreateTime());
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateTime());
}
if (successCount_ != 0L) {
size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, successCount_);
}
if (failureCount_ != 0L) {
size += com.google.protobuf.CodedOutputStream.computeInt64Size(4, failureCount_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(requestId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, requestId_);
}
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(notificationPubsubTopic_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, notificationPubsubTopic_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.cloud.retail.v2beta.ImportMetadata)) {
return super.equals(obj);
}
com.google.cloud.retail.v2beta.ImportMetadata other =
(com.google.cloud.retail.v2beta.ImportMetadata) obj;
if (hasCreateTime() != other.hasCreateTime()) return false;
if (hasCreateTime()) {
if (!getCreateTime().equals(other.getCreateTime())) return false;
}
if (hasUpdateTime() != other.hasUpdateTime()) return false;
if (hasUpdateTime()) {
if (!getUpdateTime().equals(other.getUpdateTime())) return false;
}
if (getSuccessCount() != other.getSuccessCount()) return false;
if (getFailureCount() != other.getFailureCount()) return false;
if (!getRequestId().equals(other.getRequestId())) return false;
if (!getNotificationPubsubTopic().equals(other.getNotificationPubsubTopic())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasCreateTime()) {
hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER;
hash = (53 * hash) + getCreateTime().hashCode();
}
if (hasUpdateTime()) {
hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER;
hash = (53 * hash) + getUpdateTime().hashCode();
}
hash = (37 * hash) + SUCCESS_COUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getSuccessCount());
hash = (37 * hash) + FAILURE_COUNT_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getFailureCount());
hash = (37 * hash) + REQUEST_ID_FIELD_NUMBER;
hash = (53 * hash) + getRequestId().hashCode();
hash = (37 * hash) + NOTIFICATION_PUBSUB_TOPIC_FIELD_NUMBER;
hash = (53 * hash) + getNotificationPubsubTopic().hashCode();
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
PARSER, input, extensionRegistry);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseDelimitedFrom(
java.io.InputStream input) throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseDelimitedFrom(
java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
PARSER, input, extensionRegistry);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
com.google.protobuf.CodedInputStream input) throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
}
public static com.google.cloud.retail.v2beta.ImportMetadata parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() {
return newBuilder();
}
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.cloud.retail.v2beta.ImportMetadata prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
*
*
* Metadata related to the progress of the Import operation. This is
* returned by the google.longrunning.Operation.metadata field.
*
*
* Protobuf type {@code google.cloud.retail.v2beta.ImportMetadata}
*/
public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
implements
// @@protoc_insertion_point(builder_implements:google.cloud.retail.v2beta.ImportMetadata)
com.google.cloud.retail.v2beta.ImportMetadataOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
return com.google.cloud.retail.v2beta.ImportConfigProto
.internal_static_google_cloud_retail_v2beta_ImportMetadata_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.cloud.retail.v2beta.ImportConfigProto
.internal_static_google_cloud_retail_v2beta_ImportMetadata_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.cloud.retail.v2beta.ImportMetadata.class,
com.google.cloud.retail.v2beta.ImportMetadata.Builder.class);
}
// Construct using com.google.cloud.retail.v2beta.ImportMetadata.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {
getCreateTimeFieldBuilder();
getUpdateTimeFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
createTime_ = null;
if (createTimeBuilder_ != null) {
createTimeBuilder_.dispose();
createTimeBuilder_ = null;
}
updateTime_ = null;
if (updateTimeBuilder_ != null) {
updateTimeBuilder_.dispose();
updateTimeBuilder_ = null;
}
successCount_ = 0L;
failureCount_ = 0L;
requestId_ = "";
notificationPubsubTopic_ = "";
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
return com.google.cloud.retail.v2beta.ImportConfigProto
.internal_static_google_cloud_retail_v2beta_ImportMetadata_descriptor;
}
@java.lang.Override
public com.google.cloud.retail.v2beta.ImportMetadata getDefaultInstanceForType() {
return com.google.cloud.retail.v2beta.ImportMetadata.getDefaultInstance();
}
@java.lang.Override
public com.google.cloud.retail.v2beta.ImportMetadata build() {
com.google.cloud.retail.v2beta.ImportMetadata result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.cloud.retail.v2beta.ImportMetadata buildPartial() {
com.google.cloud.retail.v2beta.ImportMetadata result =
new com.google.cloud.retail.v2beta.ImportMetadata(this);
if (bitField0_ != 0) {
buildPartial0(result);
}
onBuilt();
return result;
}
private void buildPartial0(com.google.cloud.retail.v2beta.ImportMetadata result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.createTime_ = createTimeBuilder_ == null ? createTime_ : createTimeBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.updateTime_ = updateTimeBuilder_ == null ? updateTime_ : updateTimeBuilder_.build();
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.successCount_ = successCount_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.failureCount_ = failureCount_;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.requestId_ = requestId_;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
result.notificationPubsubTopic_ = notificationPubsubTopic_;
}
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 com.google.cloud.retail.v2beta.ImportMetadata) {
return mergeFrom((com.google.cloud.retail.v2beta.ImportMetadata) other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.cloud.retail.v2beta.ImportMetadata other) {
if (other == com.google.cloud.retail.v2beta.ImportMetadata.getDefaultInstance()) return this;
if (other.hasCreateTime()) {
mergeCreateTime(other.getCreateTime());
}
if (other.hasUpdateTime()) {
mergeUpdateTime(other.getUpdateTime());
}
if (other.getSuccessCount() != 0L) {
setSuccessCount(other.getSuccessCount());
}
if (other.getFailureCount() != 0L) {
setFailureCount(other.getFailureCount());
}
if (!other.getRequestId().isEmpty()) {
requestId_ = other.requestId_;
bitField0_ |= 0x00000010;
onChanged();
}
if (!other.getNotificationPubsubTopic().isEmpty()) {
notificationPubsubTopic_ = other.notificationPubsubTopic_;
bitField0_ |= 0x00000020;
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:
{
input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
case 18:
{
input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry);
bitField0_ |= 0x00000002;
break;
} // case 18
case 24:
{
successCount_ = input.readInt64();
bitField0_ |= 0x00000004;
break;
} // case 24
case 32:
{
failureCount_ = input.readInt64();
bitField0_ |= 0x00000008;
break;
} // case 32
case 42:
{
requestId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000010;
break;
} // case 42
case 50:
{
notificationPubsubTopic_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000020;
break;
} // case 50
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 com.google.protobuf.Timestamp createTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp,
com.google.protobuf.Timestamp.Builder,
com.google.protobuf.TimestampOrBuilder>
createTimeBuilder_;
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*
* @return Whether the createTime field is set.
*/
public boolean hasCreateTime() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*
* @return The createTime.
*/
public com.google.protobuf.Timestamp getCreateTime() {
if (createTimeBuilder_ == null) {
return createTime_ == null
? com.google.protobuf.Timestamp.getDefaultInstance()
: createTime_;
} else {
return createTimeBuilder_.getMessage();
}
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
public Builder setCreateTime(com.google.protobuf.Timestamp value) {
if (createTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
createTime_ = value;
} else {
createTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) {
if (createTimeBuilder_ == null) {
createTime_ = builderForValue.build();
} else {
createTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
public Builder mergeCreateTime(com.google.protobuf.Timestamp value) {
if (createTimeBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)
&& createTime_ != null
&& createTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
getCreateTimeBuilder().mergeFrom(value);
} else {
createTime_ = value;
}
} else {
createTimeBuilder_.mergeFrom(value);
}
if (createTime_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this;
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
public Builder clearCreateTime() {
bitField0_ = (bitField0_ & ~0x00000001);
createTime_ = null;
if (createTimeBuilder_ != null) {
createTimeBuilder_.dispose();
createTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() {
bitField0_ |= 0x00000001;
onChanged();
return getCreateTimeFieldBuilder().getBuilder();
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() {
if (createTimeBuilder_ != null) {
return createTimeBuilder_.getMessageOrBuilder();
} else {
return createTime_ == null
? com.google.protobuf.Timestamp.getDefaultInstance()
: createTime_;
}
}
/**
*
*
*
* Operation create time.
*
*
* .google.protobuf.Timestamp create_time = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp,
com.google.protobuf.Timestamp.Builder,
com.google.protobuf.TimestampOrBuilder>
getCreateTimeFieldBuilder() {
if (createTimeBuilder_ == null) {
createTimeBuilder_ =
new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp,
com.google.protobuf.Timestamp.Builder,
com.google.protobuf.TimestampOrBuilder>(
getCreateTime(), getParentForChildren(), isClean());
createTime_ = null;
}
return createTimeBuilder_;
}
private com.google.protobuf.Timestamp updateTime_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp,
com.google.protobuf.Timestamp.Builder,
com.google.protobuf.TimestampOrBuilder>
updateTimeBuilder_;
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*
* @return Whether the updateTime field is set.
*/
public boolean hasUpdateTime() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*
* @return The updateTime.
*/
public com.google.protobuf.Timestamp getUpdateTime() {
if (updateTimeBuilder_ == null) {
return updateTime_ == null
? com.google.protobuf.Timestamp.getDefaultInstance()
: updateTime_;
} else {
return updateTimeBuilder_.getMessage();
}
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
public Builder setUpdateTime(com.google.protobuf.Timestamp value) {
if (updateTimeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
updateTime_ = value;
} else {
updateTimeBuilder_.setMessage(value);
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) {
if (updateTimeBuilder_ == null) {
updateTime_ = builderForValue.build();
} else {
updateTimeBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) {
if (updateTimeBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)
&& updateTime_ != null
&& updateTime_ != com.google.protobuf.Timestamp.getDefaultInstance()) {
getUpdateTimeBuilder().mergeFrom(value);
} else {
updateTime_ = value;
}
} else {
updateTimeBuilder_.mergeFrom(value);
}
if (updateTime_ != null) {
bitField0_ |= 0x00000002;
onChanged();
}
return this;
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
public Builder clearUpdateTime() {
bitField0_ = (bitField0_ & ~0x00000002);
updateTime_ = null;
if (updateTimeBuilder_ != null) {
updateTimeBuilder_.dispose();
updateTimeBuilder_ = null;
}
onChanged();
return this;
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() {
bitField0_ |= 0x00000002;
onChanged();
return getUpdateTimeFieldBuilder().getBuilder();
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() {
if (updateTimeBuilder_ != null) {
return updateTimeBuilder_.getMessageOrBuilder();
} else {
return updateTime_ == null
? com.google.protobuf.Timestamp.getDefaultInstance()
: updateTime_;
}
}
/**
*
*
*
* Operation last update time. If the operation is done, this is also the
* finish time.
*
*
* .google.protobuf.Timestamp update_time = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp,
com.google.protobuf.Timestamp.Builder,
com.google.protobuf.TimestampOrBuilder>
getUpdateTimeFieldBuilder() {
if (updateTimeBuilder_ == null) {
updateTimeBuilder_ =
new com.google.protobuf.SingleFieldBuilderV3<
com.google.protobuf.Timestamp,
com.google.protobuf.Timestamp.Builder,
com.google.protobuf.TimestampOrBuilder>(
getUpdateTime(), getParentForChildren(), isClean());
updateTime_ = null;
}
return updateTimeBuilder_;
}
private long successCount_;
/**
*
*
*
* Count of entries that were processed successfully.
*
*
* int64 success_count = 3;
*
* @return The successCount.
*/
@java.lang.Override
public long getSuccessCount() {
return successCount_;
}
/**
*
*
*
* Count of entries that were processed successfully.
*
*
* int64 success_count = 3;
*
* @param value The successCount to set.
* @return This builder for chaining.
*/
public Builder setSuccessCount(long value) {
successCount_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
*
*
* Count of entries that were processed successfully.
*
*
* int64 success_count = 3;
*
* @return This builder for chaining.
*/
public Builder clearSuccessCount() {
bitField0_ = (bitField0_ & ~0x00000004);
successCount_ = 0L;
onChanged();
return this;
}
private long failureCount_;
/**
*
*
*
* Count of entries that encountered errors while processing.
*
*
* int64 failure_count = 4;
*
* @return The failureCount.
*/
@java.lang.Override
public long getFailureCount() {
return failureCount_;
}
/**
*
*
*
* Count of entries that encountered errors while processing.
*
*
* int64 failure_count = 4;
*
* @param value The failureCount to set.
* @return This builder for chaining.
*/
public Builder setFailureCount(long value) {
failureCount_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
*
*
* Count of entries that encountered errors while processing.
*
*
* int64 failure_count = 4;
*
* @return This builder for chaining.
*/
public Builder clearFailureCount() {
bitField0_ = (bitField0_ & ~0x00000008);
failureCount_ = 0L;
onChanged();
return this;
}
private java.lang.Object requestId_ = "";
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @return The requestId.
*/
@java.lang.Deprecated
public java.lang.String getRequestId() {
java.lang.Object ref = requestId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
requestId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @return The bytes for requestId.
*/
@java.lang.Deprecated
public com.google.protobuf.ByteString getRequestIdBytes() {
java.lang.Object ref = requestId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
requestId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @param value The requestId to set.
* @return This builder for chaining.
*/
@java.lang.Deprecated
public Builder setRequestId(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
requestId_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @return This builder for chaining.
*/
@java.lang.Deprecated
public Builder clearRequestId() {
requestId_ = getDefaultInstance().getRequestId();
bitField0_ = (bitField0_ & ~0x00000010);
onChanged();
return this;
}
/**
*
*
*
* Deprecated. This field is never set.
*
*
* string request_id = 5 [deprecated = true];
*
* @deprecated google.cloud.retail.v2beta.ImportMetadata.request_id is deprecated. See
* google/cloud/retail/v2beta/import_config.proto;l=336
* @param value The bytes for requestId to set.
* @return This builder for chaining.
*/
@java.lang.Deprecated
public Builder setRequestIdBytes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
requestId_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
private java.lang.Object notificationPubsubTopic_ = "";
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @return The notificationPubsubTopic.
*/
public java.lang.String getNotificationPubsubTopic() {
java.lang.Object ref = notificationPubsubTopic_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
notificationPubsubTopic_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @return The bytes for notificationPubsubTopic.
*/
public com.google.protobuf.ByteString getNotificationPubsubTopicBytes() {
java.lang.Object ref = notificationPubsubTopic_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref);
notificationPubsubTopic_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @param value The notificationPubsubTopic to set.
* @return This builder for chaining.
*/
public Builder setNotificationPubsubTopic(java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
notificationPubsubTopic_ = value;
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @return This builder for chaining.
*/
public Builder clearNotificationPubsubTopic() {
notificationPubsubTopic_ = getDefaultInstance().getNotificationPubsubTopic();
bitField0_ = (bitField0_ & ~0x00000020);
onChanged();
return this;
}
/**
*
*
*
* Pub/Sub topic for receiving notification. If this field is set,
* when the import is finished, a notification is sent to
* specified Pub/Sub topic. The message data is JSON string of a
* [Operation][google.longrunning.Operation].
* Format of the Pub/Sub topic is `projects/{project}/topics/{topic}`.
*
*
* string notification_pubsub_topic = 6;
*
* @param value The bytes for notificationPubsubTopic to set.
* @return This builder for chaining.
*/
public Builder setNotificationPubsubTopicBytes(com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
notificationPubsubTopic_ = value;
bitField0_ |= 0x00000020;
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:google.cloud.retail.v2beta.ImportMetadata)
}
// @@protoc_insertion_point(class_scope:google.cloud.retail.v2beta.ImportMetadata)
private static final com.google.cloud.retail.v2beta.ImportMetadata DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.cloud.retail.v2beta.ImportMetadata();
}
public static com.google.cloud.retail.v2beta.ImportMetadata getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser PARSER =
new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ImportMetadata 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 com.google.cloud.retail.v2beta.ImportMetadata getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}