proto.com.cognite.client.dto.ConvertResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of cdf-sdk-java Show documentation
Show all versions of cdf-sdk-java Show documentation
Java SDK for reading and writing from/to CDF resources.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: diagram_response.proto
package com.cognite.client.dto;
/**
* Protobuf type {@code com.cognite.beam.proto.ConvertResponse}
*/
public final class ConvertResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:com.cognite.beam.proto.ConvertResponse)
ConvertResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use ConvertResponse.newBuilder() to construct.
private ConvertResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ConvertResponse() {
fileExternalId_ = "";
results_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ConvertResponse();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private ConvertResponse(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
bitField0_ |= 0x00000001;
fileId_ = input.readInt64();
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
fileExternalId_ = s;
break;
}
case 26: {
if (!((mutable_bitField0_ & 0x00000004) != 0)) {
results_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000004;
}
results_.add(
input.readMessage(com.cognite.client.dto.ConvertResponse.Result.parser(), extensionRegistry));
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000004) != 0)) {
results_ = java.util.Collections.unmodifiableList(results_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.cognite.client.dto.ConvertResponse.class, com.cognite.client.dto.ConvertResponse.Builder.class);
}
public interface ResultOrBuilder extends
// @@protoc_insertion_point(interface_extends:com.cognite.beam.proto.ConvertResponse.Result)
com.google.protobuf.MessageOrBuilder {
/**
* int32 page = 1;
* @return The page.
*/
int getPage();
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return Whether the svgUrl field is set.
*/
boolean hasSvgUrl();
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return The svgUrl.
*/
java.lang.String getSvgUrl();
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return The bytes for svgUrl.
*/
com.google.protobuf.ByteString
getSvgUrlBytes();
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return Whether the pngUrl field is set.
*/
boolean hasPngUrl();
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return The pngUrl.
*/
java.lang.String getPngUrl();
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return The bytes for pngUrl.
*/
com.google.protobuf.ByteString
getPngUrlBytes();
/**
* optional string error_message = 4;
* @return Whether the errorMessage field is set.
*/
boolean hasErrorMessage();
/**
* optional string error_message = 4;
* @return The errorMessage.
*/
java.lang.String getErrorMessage();
/**
* optional string error_message = 4;
* @return The bytes for errorMessage.
*/
com.google.protobuf.ByteString
getErrorMessageBytes();
}
/**
* Protobuf type {@code com.cognite.beam.proto.ConvertResponse.Result}
*/
public static final class Result extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:com.cognite.beam.proto.ConvertResponse.Result)
ResultOrBuilder {
private static final long serialVersionUID = 0L;
// Use Result.newBuilder() to construct.
private Result(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Result() {
svgUrl_ = "";
pngUrl_ = "";
errorMessage_ = "";
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new Result();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Result(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
int mutable_bitField0_ = 0;
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
com.google.protobuf.UnknownFieldSet.newBuilder();
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
page_ = input.readInt32();
break;
}
case 18: {
java.lang.String s = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
svgUrl_ = s;
break;
}
case 26: {
java.lang.String s = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
pngUrl_ = s;
break;
}
case 34: {
java.lang.String s = input.readStringRequireUtf8();
bitField0_ |= 0x00000004;
errorMessage_ = s;
break;
}
default: {
if (!parseUnknownField(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_Result_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_Result_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.cognite.client.dto.ConvertResponse.Result.class, com.cognite.client.dto.ConvertResponse.Result.Builder.class);
}
private int bitField0_;
public static final int PAGE_FIELD_NUMBER = 1;
private int page_;
/**
* int32 page = 1;
* @return The page.
*/
@java.lang.Override
public int getPage() {
return page_;
}
public static final int SVG_URL_FIELD_NUMBER = 2;
private volatile java.lang.Object svgUrl_;
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return Whether the svgUrl field is set.
*/
@java.lang.Override
public boolean hasSvgUrl() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return The svgUrl.
*/
@java.lang.Override
public java.lang.String getSvgUrl() {
java.lang.Object ref = svgUrl_;
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();
svgUrl_ = s;
return s;
}
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return The bytes for svgUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getSvgUrlBytes() {
java.lang.Object ref = svgUrl_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
svgUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int PNG_URL_FIELD_NUMBER = 3;
private volatile java.lang.Object pngUrl_;
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return Whether the pngUrl field is set.
*/
@java.lang.Override
public boolean hasPngUrl() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return The pngUrl.
*/
@java.lang.Override
public java.lang.String getPngUrl() {
java.lang.Object ref = pngUrl_;
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();
pngUrl_ = s;
return s;
}
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return The bytes for pngUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getPngUrlBytes() {
java.lang.Object ref = pngUrl_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
pngUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int ERROR_MESSAGE_FIELD_NUMBER = 4;
private volatile java.lang.Object errorMessage_;
/**
* optional string error_message = 4;
* @return Whether the errorMessage field is set.
*/
@java.lang.Override
public boolean hasErrorMessage() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
* optional string error_message = 4;
* @return The errorMessage.
*/
@java.lang.Override
public java.lang.String getErrorMessage() {
java.lang.Object ref = errorMessage_;
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();
errorMessage_ = s;
return s;
}
}
/**
* optional string error_message = 4;
* @return The bytes for errorMessage.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getErrorMessageBytes() {
java.lang.Object ref = errorMessage_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
errorMessage_ = 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 (page_ != 0) {
output.writeInt32(1, page_);
}
if (((bitField0_ & 0x00000001) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, svgUrl_);
}
if (((bitField0_ & 0x00000002) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pngUrl_);
}
if (((bitField0_ & 0x00000004) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 4, errorMessage_);
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (page_ != 0) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(1, page_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, svgUrl_);
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pngUrl_);
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, errorMessage_);
}
size += unknownFields.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.cognite.client.dto.ConvertResponse.Result)) {
return super.equals(obj);
}
com.cognite.client.dto.ConvertResponse.Result other = (com.cognite.client.dto.ConvertResponse.Result) obj;
if (getPage()
!= other.getPage()) return false;
if (hasSvgUrl() != other.hasSvgUrl()) return false;
if (hasSvgUrl()) {
if (!getSvgUrl()
.equals(other.getSvgUrl())) return false;
}
if (hasPngUrl() != other.hasPngUrl()) return false;
if (hasPngUrl()) {
if (!getPngUrl()
.equals(other.getPngUrl())) return false;
}
if (hasErrorMessage() != other.hasErrorMessage()) return false;
if (hasErrorMessage()) {
if (!getErrorMessage()
.equals(other.getErrorMessage())) return false;
}
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + PAGE_FIELD_NUMBER;
hash = (53 * hash) + getPage();
if (hasSvgUrl()) {
hash = (37 * hash) + SVG_URL_FIELD_NUMBER;
hash = (53 * hash) + getSvgUrl().hashCode();
}
if (hasPngUrl()) {
hash = (37 * hash) + PNG_URL_FIELD_NUMBER;
hash = (53 * hash) + getPngUrl().hashCode();
}
if (hasErrorMessage()) {
hash = (37 * hash) + ERROR_MESSAGE_FIELD_NUMBER;
hash = (53 * hash) + getErrorMessage().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.cognite.client.dto.ConvertResponse.Result parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.cognite.client.dto.ConvertResponse.Result 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.cognite.client.dto.ConvertResponse.Result parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.cognite.client.dto.ConvertResponse.Result 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.cognite.client.dto.ConvertResponse.Result parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.cognite.client.dto.ConvertResponse.Result 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.cognite.client.dto.ConvertResponse.Result 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;
}
/**
* Protobuf type {@code com.cognite.beam.proto.ConvertResponse.Result}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:com.cognite.beam.proto.ConvertResponse.Result)
com.cognite.client.dto.ConvertResponse.ResultOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_Result_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_Result_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.cognite.client.dto.ConvertResponse.Result.class, com.cognite.client.dto.ConvertResponse.Result.Builder.class);
}
// Construct using com.cognite.client.dto.ConvertResponse.Result.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
page_ = 0;
svgUrl_ = "";
bitField0_ = (bitField0_ & ~0x00000001);
pngUrl_ = "";
bitField0_ = (bitField0_ & ~0x00000002);
errorMessage_ = "";
bitField0_ = (bitField0_ & ~0x00000004);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_Result_descriptor;
}
@java.lang.Override
public com.cognite.client.dto.ConvertResponse.Result getDefaultInstanceForType() {
return com.cognite.client.dto.ConvertResponse.Result.getDefaultInstance();
}
@java.lang.Override
public com.cognite.client.dto.ConvertResponse.Result build() {
com.cognite.client.dto.ConvertResponse.Result result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.cognite.client.dto.ConvertResponse.Result buildPartial() {
com.cognite.client.dto.ConvertResponse.Result result = new com.cognite.client.dto.ConvertResponse.Result(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
result.page_ = page_;
if (((from_bitField0_ & 0x00000001) != 0)) {
to_bitField0_ |= 0x00000001;
}
result.svgUrl_ = svgUrl_;
if (((from_bitField0_ & 0x00000002) != 0)) {
to_bitField0_ |= 0x00000002;
}
result.pngUrl_ = pngUrl_;
if (((from_bitField0_ & 0x00000004) != 0)) {
to_bitField0_ |= 0x00000004;
}
result.errorMessage_ = errorMessage_;
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
@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.cognite.client.dto.ConvertResponse.Result) {
return mergeFrom((com.cognite.client.dto.ConvertResponse.Result)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.cognite.client.dto.ConvertResponse.Result other) {
if (other == com.cognite.client.dto.ConvertResponse.Result.getDefaultInstance()) return this;
if (other.getPage() != 0) {
setPage(other.getPage());
}
if (other.hasSvgUrl()) {
bitField0_ |= 0x00000001;
svgUrl_ = other.svgUrl_;
onChanged();
}
if (other.hasPngUrl()) {
bitField0_ |= 0x00000002;
pngUrl_ = other.pngUrl_;
onChanged();
}
if (other.hasErrorMessage()) {
bitField0_ |= 0x00000004;
errorMessage_ = other.errorMessage_;
onChanged();
}
this.mergeUnknownFields(other.unknownFields);
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 {
com.cognite.client.dto.ConvertResponse.Result parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.cognite.client.dto.ConvertResponse.Result) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private int page_ ;
/**
* int32 page = 1;
* @return The page.
*/
@java.lang.Override
public int getPage() {
return page_;
}
/**
* int32 page = 1;
* @param value The page to set.
* @return This builder for chaining.
*/
public Builder setPage(int value) {
page_ = value;
onChanged();
return this;
}
/**
* int32 page = 1;
* @return This builder for chaining.
*/
public Builder clearPage() {
page_ = 0;
onChanged();
return this;
}
private java.lang.Object svgUrl_ = "";
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return Whether the svgUrl field is set.
*/
public boolean hasSvgUrl() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return The svgUrl.
*/
public java.lang.String getSvgUrl() {
java.lang.Object ref = svgUrl_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
svgUrl_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return The bytes for svgUrl.
*/
public com.google.protobuf.ByteString
getSvgUrlBytes() {
java.lang.Object ref = svgUrl_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
svgUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @param value The svgUrl to set.
* @return This builder for chaining.
*/
public Builder setSvgUrl(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
svgUrl_ = value;
onChanged();
return this;
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @return This builder for chaining.
*/
public Builder clearSvgUrl() {
bitField0_ = (bitField0_ & ~0x00000001);
svgUrl_ = getDefaultInstance().getSvgUrl();
onChanged();
return this;
}
/**
*
* The URL for the converted SVG file
*
*
* optional string svg_url = 2;
* @param value The bytes for svgUrl to set.
* @return This builder for chaining.
*/
public Builder setSvgUrlBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
bitField0_ |= 0x00000001;
svgUrl_ = value;
onChanged();
return this;
}
private java.lang.Object pngUrl_ = "";
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return Whether the pngUrl field is set.
*/
public boolean hasPngUrl() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return The pngUrl.
*/
public java.lang.String getPngUrl() {
java.lang.Object ref = pngUrl_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
pngUrl_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return The bytes for pngUrl.
*/
public com.google.protobuf.ByteString
getPngUrlBytes() {
java.lang.Object ref = pngUrl_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
pngUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @param value The pngUrl to set.
* @return This builder for chaining.
*/
public Builder setPngUrl(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000002;
pngUrl_ = value;
onChanged();
return this;
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @return This builder for chaining.
*/
public Builder clearPngUrl() {
bitField0_ = (bitField0_ & ~0x00000002);
pngUrl_ = getDefaultInstance().getPngUrl();
onChanged();
return this;
}
/**
*
* The URL for the converted PNG file
*
*
* optional string png_url = 3;
* @param value The bytes for pngUrl to set.
* @return This builder for chaining.
*/
public Builder setPngUrlBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
bitField0_ |= 0x00000002;
pngUrl_ = value;
onChanged();
return this;
}
private java.lang.Object errorMessage_ = "";
/**
* optional string error_message = 4;
* @return Whether the errorMessage field is set.
*/
public boolean hasErrorMessage() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
* optional string error_message = 4;
* @return The errorMessage.
*/
public java.lang.String getErrorMessage() {
java.lang.Object ref = errorMessage_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
errorMessage_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* optional string error_message = 4;
* @return The bytes for errorMessage.
*/
public com.google.protobuf.ByteString
getErrorMessageBytes() {
java.lang.Object ref = errorMessage_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
errorMessage_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* optional string error_message = 4;
* @param value The errorMessage to set.
* @return This builder for chaining.
*/
public Builder setErrorMessage(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000004;
errorMessage_ = value;
onChanged();
return this;
}
/**
* optional string error_message = 4;
* @return This builder for chaining.
*/
public Builder clearErrorMessage() {
bitField0_ = (bitField0_ & ~0x00000004);
errorMessage_ = getDefaultInstance().getErrorMessage();
onChanged();
return this;
}
/**
* optional string error_message = 4;
* @param value The bytes for errorMessage to set.
* @return This builder for chaining.
*/
public Builder setErrorMessageBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
bitField0_ |= 0x00000004;
errorMessage_ = value;
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:com.cognite.beam.proto.ConvertResponse.Result)
}
// @@protoc_insertion_point(class_scope:com.cognite.beam.proto.ConvertResponse.Result)
private static final com.cognite.client.dto.ConvertResponse.Result DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.cognite.client.dto.ConvertResponse.Result();
}
public static com.cognite.client.dto.ConvertResponse.Result getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Result parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new Result(input, extensionRegistry);
}
};
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.cognite.client.dto.ConvertResponse.Result getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private int bitField0_;
public static final int FILE_ID_FIELD_NUMBER = 1;
private long fileId_;
/**
*
*The id of the source file used for building
*interactive P&ID
*
*
* optional int64 file_id = 1;
* @return Whether the fileId field is set.
*/
@java.lang.Override
public boolean hasFileId() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
*The id of the source file used for building
*interactive P&ID
*
*
* optional int64 file_id = 1;
* @return The fileId.
*/
@java.lang.Override
public long getFileId() {
return fileId_;
}
public static final int FILE_EXTERNAL_ID_FIELD_NUMBER = 2;
private volatile java.lang.Object fileExternalId_;
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return Whether the fileExternalId field is set.
*/
@java.lang.Override
public boolean hasFileExternalId() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return The fileExternalId.
*/
@java.lang.Override
public java.lang.String getFileExternalId() {
java.lang.Object ref = fileExternalId_;
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();
fileExternalId_ = s;
return s;
}
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return The bytes for fileExternalId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getFileExternalIdBytes() {
java.lang.Object ref = fileExternalId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
fileExternalId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int RESULTS_FIELD_NUMBER = 3;
private java.util.List results_;
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
@java.lang.Override
public java.util.List getResultsList() {
return results_;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
@java.lang.Override
public java.util.List extends com.cognite.client.dto.ConvertResponse.ResultOrBuilder>
getResultsOrBuilderList() {
return results_;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
@java.lang.Override
public int getResultsCount() {
return results_.size();
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
@java.lang.Override
public com.cognite.client.dto.ConvertResponse.Result getResults(int index) {
return results_.get(index);
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
@java.lang.Override
public com.cognite.client.dto.ConvertResponse.ResultOrBuilder getResultsOrBuilder(
int index) {
return results_.get(index);
}
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.writeInt64(1, fileId_);
}
if (((bitField0_ & 0x00000002) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, fileExternalId_);
}
for (int i = 0; i < results_.size(); i++) {
output.writeMessage(3, results_.get(i));
}
unknownFields.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
.computeInt64Size(1, fileId_);
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, fileExternalId_);
}
for (int i = 0; i < results_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, results_.get(i));
}
size += unknownFields.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.cognite.client.dto.ConvertResponse)) {
return super.equals(obj);
}
com.cognite.client.dto.ConvertResponse other = (com.cognite.client.dto.ConvertResponse) obj;
if (hasFileId() != other.hasFileId()) return false;
if (hasFileId()) {
if (getFileId()
!= other.getFileId()) return false;
}
if (hasFileExternalId() != other.hasFileExternalId()) return false;
if (hasFileExternalId()) {
if (!getFileExternalId()
.equals(other.getFileExternalId())) return false;
}
if (!getResultsList()
.equals(other.getResultsList())) return false;
if (!unknownFields.equals(other.unknownFields)) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasFileId()) {
hash = (37 * hash) + FILE_ID_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getFileId());
}
if (hasFileExternalId()) {
hash = (37 * hash) + FILE_EXTERNAL_ID_FIELD_NUMBER;
hash = (53 * hash) + getFileExternalId().hashCode();
}
if (getResultsCount() > 0) {
hash = (37 * hash) + RESULTS_FIELD_NUMBER;
hash = (53 * hash) + getResultsList().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.cognite.client.dto.ConvertResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.cognite.client.dto.ConvertResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.cognite.client.dto.ConvertResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.cognite.client.dto.ConvertResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.cognite.client.dto.ConvertResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.cognite.client.dto.ConvertResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.cognite.client.dto.ConvertResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.cognite.client.dto.ConvertResponse 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.cognite.client.dto.ConvertResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.cognite.client.dto.ConvertResponse 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.cognite.client.dto.ConvertResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.cognite.client.dto.ConvertResponse 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.cognite.client.dto.ConvertResponse 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;
}
/**
* Protobuf type {@code com.cognite.beam.proto.ConvertResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:com.cognite.beam.proto.ConvertResponse)
com.cognite.client.dto.ConvertResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.cognite.client.dto.ConvertResponse.class, com.cognite.client.dto.ConvertResponse.Builder.class);
}
// Construct using com.cognite.client.dto.ConvertResponse.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getResultsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
fileId_ = 0L;
bitField0_ = (bitField0_ & ~0x00000001);
fileExternalId_ = "";
bitField0_ = (bitField0_ & ~0x00000002);
if (resultsBuilder_ == null) {
results_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
} else {
resultsBuilder_.clear();
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.cognite.client.dto.DiagramResponseOuterClass.internal_static_com_cognite_beam_proto_ConvertResponse_descriptor;
}
@java.lang.Override
public com.cognite.client.dto.ConvertResponse getDefaultInstanceForType() {
return com.cognite.client.dto.ConvertResponse.getDefaultInstance();
}
@java.lang.Override
public com.cognite.client.dto.ConvertResponse build() {
com.cognite.client.dto.ConvertResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.cognite.client.dto.ConvertResponse buildPartial() {
com.cognite.client.dto.ConvertResponse result = new com.cognite.client.dto.ConvertResponse(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.fileId_ = fileId_;
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
to_bitField0_ |= 0x00000002;
}
result.fileExternalId_ = fileExternalId_;
if (resultsBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0)) {
results_ = java.util.Collections.unmodifiableList(results_);
bitField0_ = (bitField0_ & ~0x00000004);
}
result.results_ = results_;
} else {
result.results_ = resultsBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
@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.cognite.client.dto.ConvertResponse) {
return mergeFrom((com.cognite.client.dto.ConvertResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.cognite.client.dto.ConvertResponse other) {
if (other == com.cognite.client.dto.ConvertResponse.getDefaultInstance()) return this;
if (other.hasFileId()) {
setFileId(other.getFileId());
}
if (other.hasFileExternalId()) {
bitField0_ |= 0x00000002;
fileExternalId_ = other.fileExternalId_;
onChanged();
}
if (resultsBuilder_ == null) {
if (!other.results_.isEmpty()) {
if (results_.isEmpty()) {
results_ = other.results_;
bitField0_ = (bitField0_ & ~0x00000004);
} else {
ensureResultsIsMutable();
results_.addAll(other.results_);
}
onChanged();
}
} else {
if (!other.results_.isEmpty()) {
if (resultsBuilder_.isEmpty()) {
resultsBuilder_.dispose();
resultsBuilder_ = null;
results_ = other.results_;
bitField0_ = (bitField0_ & ~0x00000004);
resultsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getResultsFieldBuilder() : null;
} else {
resultsBuilder_.addAllMessages(other.results_);
}
}
}
this.mergeUnknownFields(other.unknownFields);
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 {
com.cognite.client.dto.ConvertResponse parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (com.cognite.client.dto.ConvertResponse) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private long fileId_ ;
/**
*
*The id of the source file used for building
*interactive P&ID
*
*
* optional int64 file_id = 1;
* @return Whether the fileId field is set.
*/
@java.lang.Override
public boolean hasFileId() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
*The id of the source file used for building
*interactive P&ID
*
*
* optional int64 file_id = 1;
* @return The fileId.
*/
@java.lang.Override
public long getFileId() {
return fileId_;
}
/**
*
*The id of the source file used for building
*interactive P&ID
*
*
* optional int64 file_id = 1;
* @param value The fileId to set.
* @return This builder for chaining.
*/
public Builder setFileId(long value) {
bitField0_ |= 0x00000001;
fileId_ = value;
onChanged();
return this;
}
/**
*
*The id of the source file used for building
*interactive P&ID
*
*
* optional int64 file_id = 1;
* @return This builder for chaining.
*/
public Builder clearFileId() {
bitField0_ = (bitField0_ & ~0x00000001);
fileId_ = 0L;
onChanged();
return this;
}
private java.lang.Object fileExternalId_ = "";
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return Whether the fileExternalId field is set.
*/
public boolean hasFileExternalId() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return The fileExternalId.
*/
public java.lang.String getFileExternalId() {
java.lang.Object ref = fileExternalId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
fileExternalId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return The bytes for fileExternalId.
*/
public com.google.protobuf.ByteString
getFileExternalIdBytes() {
java.lang.Object ref = fileExternalId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
fileExternalId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @param value The fileExternalId to set.
* @return This builder for chaining.
*/
public Builder setFileExternalId(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000002;
fileExternalId_ = value;
onChanged();
return this;
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @return This builder for chaining.
*/
public Builder clearFileExternalId() {
bitField0_ = (bitField0_ & ~0x00000002);
fileExternalId_ = getDefaultInstance().getFileExternalId();
onChanged();
return this;
}
/**
*
*The external id of the source file used for building
*interactive P&ID
*
*
* optional string file_external_id = 2;
* @param value The bytes for fileExternalId to set.
* @return This builder for chaining.
*/
public Builder setFileExternalIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
bitField0_ |= 0x00000002;
fileExternalId_ = value;
onChanged();
return this;
}
private java.util.List results_ =
java.util.Collections.emptyList();
private void ensureResultsIsMutable() {
if (!((bitField0_ & 0x00000004) != 0)) {
results_ = new java.util.ArrayList(results_);
bitField0_ |= 0x00000004;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.cognite.client.dto.ConvertResponse.Result, com.cognite.client.dto.ConvertResponse.Result.Builder, com.cognite.client.dto.ConvertResponse.ResultOrBuilder> resultsBuilder_;
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public java.util.List getResultsList() {
if (resultsBuilder_ == null) {
return java.util.Collections.unmodifiableList(results_);
} else {
return resultsBuilder_.getMessageList();
}
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public int getResultsCount() {
if (resultsBuilder_ == null) {
return results_.size();
} else {
return resultsBuilder_.getCount();
}
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public com.cognite.client.dto.ConvertResponse.Result getResults(int index) {
if (resultsBuilder_ == null) {
return results_.get(index);
} else {
return resultsBuilder_.getMessage(index);
}
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder setResults(
int index, com.cognite.client.dto.ConvertResponse.Result value) {
if (resultsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureResultsIsMutable();
results_.set(index, value);
onChanged();
} else {
resultsBuilder_.setMessage(index, value);
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder setResults(
int index, com.cognite.client.dto.ConvertResponse.Result.Builder builderForValue) {
if (resultsBuilder_ == null) {
ensureResultsIsMutable();
results_.set(index, builderForValue.build());
onChanged();
} else {
resultsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder addResults(com.cognite.client.dto.ConvertResponse.Result value) {
if (resultsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureResultsIsMutable();
results_.add(value);
onChanged();
} else {
resultsBuilder_.addMessage(value);
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder addResults(
int index, com.cognite.client.dto.ConvertResponse.Result value) {
if (resultsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureResultsIsMutable();
results_.add(index, value);
onChanged();
} else {
resultsBuilder_.addMessage(index, value);
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder addResults(
com.cognite.client.dto.ConvertResponse.Result.Builder builderForValue) {
if (resultsBuilder_ == null) {
ensureResultsIsMutable();
results_.add(builderForValue.build());
onChanged();
} else {
resultsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder addResults(
int index, com.cognite.client.dto.ConvertResponse.Result.Builder builderForValue) {
if (resultsBuilder_ == null) {
ensureResultsIsMutable();
results_.add(index, builderForValue.build());
onChanged();
} else {
resultsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder addAllResults(
java.lang.Iterable extends com.cognite.client.dto.ConvertResponse.Result> values) {
if (resultsBuilder_ == null) {
ensureResultsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, results_);
onChanged();
} else {
resultsBuilder_.addAllMessages(values);
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder clearResults() {
if (resultsBuilder_ == null) {
results_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
} else {
resultsBuilder_.clear();
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public Builder removeResults(int index) {
if (resultsBuilder_ == null) {
ensureResultsIsMutable();
results_.remove(index);
onChanged();
} else {
resultsBuilder_.remove(index);
}
return this;
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public com.cognite.client.dto.ConvertResponse.Result.Builder getResultsBuilder(
int index) {
return getResultsFieldBuilder().getBuilder(index);
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public com.cognite.client.dto.ConvertResponse.ResultOrBuilder getResultsOrBuilder(
int index) {
if (resultsBuilder_ == null) {
return results_.get(index); } else {
return resultsBuilder_.getMessageOrBuilder(index);
}
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public java.util.List extends com.cognite.client.dto.ConvertResponse.ResultOrBuilder>
getResultsOrBuilderList() {
if (resultsBuilder_ != null) {
return resultsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(results_);
}
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public com.cognite.client.dto.ConvertResponse.Result.Builder addResultsBuilder() {
return getResultsFieldBuilder().addBuilder(
com.cognite.client.dto.ConvertResponse.Result.getDefaultInstance());
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public com.cognite.client.dto.ConvertResponse.Result.Builder addResultsBuilder(
int index) {
return getResultsFieldBuilder().addBuilder(
index, com.cognite.client.dto.ConvertResponse.Result.getDefaultInstance());
}
/**
* repeated .com.cognite.beam.proto.ConvertResponse.Result results = 3;
*/
public java.util.List
getResultsBuilderList() {
return getResultsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.cognite.client.dto.ConvertResponse.Result, com.cognite.client.dto.ConvertResponse.Result.Builder, com.cognite.client.dto.ConvertResponse.ResultOrBuilder>
getResultsFieldBuilder() {
if (resultsBuilder_ == null) {
resultsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.cognite.client.dto.ConvertResponse.Result, com.cognite.client.dto.ConvertResponse.Result.Builder, com.cognite.client.dto.ConvertResponse.ResultOrBuilder>(
results_,
((bitField0_ & 0x00000004) != 0),
getParentForChildren(),
isClean());
results_ = null;
}
return resultsBuilder_;
}
@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:com.cognite.beam.proto.ConvertResponse)
}
// @@protoc_insertion_point(class_scope:com.cognite.beam.proto.ConvertResponse)
private static final com.cognite.client.dto.ConvertResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.cognite.client.dto.ConvertResponse();
}
public static com.cognite.client.dto.ConvertResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ConvertResponse parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new ConvertResponse(input, extensionRegistry);
}
};
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.cognite.client.dto.ConvertResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy