com.diozero.remote.message.protobuf.IntegerArrayResponse Maven / Gradle / Ivy
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: diozero.proto
// Protobuf Java Version: 4.28.2
package com.diozero.remote.message.protobuf;
/**
* Protobuf type {@code diozero.IntegerArrayResponse}
*/
public final class IntegerArrayResponse extends
com.google.protobuf.GeneratedMessage implements
// @@protoc_insertion_point(message_implements:diozero.IntegerArrayResponse)
IntegerArrayResponseOrBuilder {
private static final long serialVersionUID = 0L;
static {
com.google.protobuf.RuntimeVersion.validateProtobufGencodeVersion(
com.google.protobuf.RuntimeVersion.RuntimeDomain.PUBLIC,
/* major= */ 4,
/* minor= */ 28,
/* patch= */ 2,
/* suffix= */ "",
IntegerArrayResponse.class.getName());
}
// Use IntegerArrayResponse.newBuilder() to construct.
private IntegerArrayResponse(com.google.protobuf.GeneratedMessage.Builder> builder) {
super(builder);
}
private IntegerArrayResponse() {
status_ = 0;
detail_ = "";
data_ = emptyIntList();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.diozero.remote.message.protobuf.Diozero.internal_static_diozero_IntegerArrayResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.diozero.remote.message.protobuf.Diozero.internal_static_diozero_IntegerArrayResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.diozero.remote.message.protobuf.IntegerArrayResponse.class, com.diozero.remote.message.protobuf.IntegerArrayResponse.Builder.class);
}
public static final int STATUS_FIELD_NUMBER = 1;
private int status_ = 0;
/**
* .diozero.Status status = 1;
* @return The enum numeric value on the wire for status.
*/
@java.lang.Override public int getStatusValue() {
return status_;
}
/**
* .diozero.Status status = 1;
* @return The status.
*/
@java.lang.Override public com.diozero.remote.message.protobuf.Status getStatus() {
com.diozero.remote.message.protobuf.Status result = com.diozero.remote.message.protobuf.Status.forNumber(status_);
return result == null ? com.diozero.remote.message.protobuf.Status.UNRECOGNIZED : result;
}
public static final int DETAIL_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object detail_ = "";
/**
* string detail = 2;
* @return The detail.
*/
@java.lang.Override
public java.lang.String getDetail() {
java.lang.Object ref = detail_;
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();
detail_ = s;
return s;
}
}
/**
* string detail = 2;
* @return The bytes for detail.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getDetailBytes() {
java.lang.Object ref = detail_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
detail_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int DATA_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.IntList data_ =
emptyIntList();
/**
* repeated int32 data = 3;
* @return A list containing the data.
*/
@java.lang.Override
public java.util.List
getDataList() {
return data_;
}
/**
* repeated int32 data = 3;
* @return The count of data.
*/
public int getDataCount() {
return data_.size();
}
/**
* repeated int32 data = 3;
* @param index The index of the element to return.
* @return The data at the given index.
*/
public int getData(int index) {
return data_.getInt(index);
}
private int dataMemoizedSerializedSize = -1;
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 {
getSerializedSize();
if (status_ != com.diozero.remote.message.protobuf.Status.OK.getNumber()) {
output.writeEnum(1, status_);
}
if (!com.google.protobuf.GeneratedMessage.isStringEmpty(detail_)) {
com.google.protobuf.GeneratedMessage.writeString(output, 2, detail_);
}
if (getDataList().size() > 0) {
output.writeUInt32NoTag(26);
output.writeUInt32NoTag(dataMemoizedSerializedSize);
}
for (int i = 0; i < data_.size(); i++) {
output.writeInt32NoTag(data_.getInt(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (status_ != com.diozero.remote.message.protobuf.Status.OK.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, status_);
}
if (!com.google.protobuf.GeneratedMessage.isStringEmpty(detail_)) {
size += com.google.protobuf.GeneratedMessage.computeStringSize(2, detail_);
}
{
int dataSize = 0;
for (int i = 0; i < data_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(data_.getInt(i));
}
size += dataSize;
if (!getDataList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
dataMemoizedSerializedSize = dataSize;
}
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.diozero.remote.message.protobuf.IntegerArrayResponse)) {
return super.equals(obj);
}
com.diozero.remote.message.protobuf.IntegerArrayResponse other = (com.diozero.remote.message.protobuf.IntegerArrayResponse) obj;
if (status_ != other.status_) return false;
if (!getDetail()
.equals(other.getDetail())) return false;
if (!getDataList()
.equals(other.getDataList())) 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();
hash = (37 * hash) + STATUS_FIELD_NUMBER;
hash = (53 * hash) + status_;
hash = (37 * hash) + DETAIL_FIELD_NUMBER;
hash = (53 * hash) + getDetail().hashCode();
if (getDataCount() > 0) {
hash = (37 * hash) + DATA_FIELD_NUMBER;
hash = (53 * hash) + getDataList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessage
.parseWithIOException(PARSER, input);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessage
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessage
.parseDelimitedWithIOException(PARSER, input);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessage
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessage
.parseWithIOException(PARSER, input);
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessage
.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.diozero.remote.message.protobuf.IntegerArrayResponse 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.GeneratedMessage.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
* Protobuf type {@code diozero.IntegerArrayResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessage.Builder implements
// @@protoc_insertion_point(builder_implements:diozero.IntegerArrayResponse)
com.diozero.remote.message.protobuf.IntegerArrayResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.diozero.remote.message.protobuf.Diozero.internal_static_diozero_IntegerArrayResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.diozero.remote.message.protobuf.Diozero.internal_static_diozero_IntegerArrayResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.diozero.remote.message.protobuf.IntegerArrayResponse.class, com.diozero.remote.message.protobuf.IntegerArrayResponse.Builder.class);
}
// Construct using com.diozero.remote.message.protobuf.IntegerArrayResponse.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
status_ = 0;
detail_ = "";
data_ = emptyIntList();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.diozero.remote.message.protobuf.Diozero.internal_static_diozero_IntegerArrayResponse_descriptor;
}
@java.lang.Override
public com.diozero.remote.message.protobuf.IntegerArrayResponse getDefaultInstanceForType() {
return com.diozero.remote.message.protobuf.IntegerArrayResponse.getDefaultInstance();
}
@java.lang.Override
public com.diozero.remote.message.protobuf.IntegerArrayResponse build() {
com.diozero.remote.message.protobuf.IntegerArrayResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.diozero.remote.message.protobuf.IntegerArrayResponse buildPartial() {
com.diozero.remote.message.protobuf.IntegerArrayResponse result = new com.diozero.remote.message.protobuf.IntegerArrayResponse(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(com.diozero.remote.message.protobuf.IntegerArrayResponse result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.status_ = status_;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.detail_ = detail_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
data_.makeImmutable();
result.data_ = data_;
}
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.diozero.remote.message.protobuf.IntegerArrayResponse) {
return mergeFrom((com.diozero.remote.message.protobuf.IntegerArrayResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.diozero.remote.message.protobuf.IntegerArrayResponse other) {
if (other == com.diozero.remote.message.protobuf.IntegerArrayResponse.getDefaultInstance()) return this;
if (other.status_ != 0) {
setStatusValue(other.getStatusValue());
}
if (!other.getDetail().isEmpty()) {
detail_ = other.detail_;
bitField0_ |= 0x00000002;
onChanged();
}
if (!other.data_.isEmpty()) {
if (data_.isEmpty()) {
data_ = other.data_;
data_.makeImmutable();
bitField0_ |= 0x00000004;
} else {
ensureDataIsMutable();
data_.addAll(other.data_);
}
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 8: {
status_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
detail_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000002;
break;
} // case 18
case 24: {
int v = input.readInt32();
ensureDataIsMutable();
data_.addInt(v);
break;
} // case 24
case 26: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensureDataIsMutable();
while (input.getBytesUntilLimit() > 0) {
data_.addInt(input.readInt32());
}
input.popLimit(limit);
break;
} // case 26
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 int status_ = 0;
/**
* .diozero.Status status = 1;
* @return The enum numeric value on the wire for status.
*/
@java.lang.Override public int getStatusValue() {
return status_;
}
/**
* .diozero.Status status = 1;
* @param value The enum numeric value on the wire for status to set.
* @return This builder for chaining.
*/
public Builder setStatusValue(int value) {
status_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
* .diozero.Status status = 1;
* @return The status.
*/
@java.lang.Override
public com.diozero.remote.message.protobuf.Status getStatus() {
com.diozero.remote.message.protobuf.Status result = com.diozero.remote.message.protobuf.Status.forNumber(status_);
return result == null ? com.diozero.remote.message.protobuf.Status.UNRECOGNIZED : result;
}
/**
* .diozero.Status status = 1;
* @param value The status to set.
* @return This builder for chaining.
*/
public Builder setStatus(com.diozero.remote.message.protobuf.Status value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
status_ = value.getNumber();
onChanged();
return this;
}
/**
* .diozero.Status status = 1;
* @return This builder for chaining.
*/
public Builder clearStatus() {
bitField0_ = (bitField0_ & ~0x00000001);
status_ = 0;
onChanged();
return this;
}
private java.lang.Object detail_ = "";
/**
* string detail = 2;
* @return The detail.
*/
public java.lang.String getDetail() {
java.lang.Object ref = detail_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
detail_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
* string detail = 2;
* @return The bytes for detail.
*/
public com.google.protobuf.ByteString
getDetailBytes() {
java.lang.Object ref = detail_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
detail_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
* string detail = 2;
* @param value The detail to set.
* @return This builder for chaining.
*/
public Builder setDetail(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
detail_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
* string detail = 2;
* @return This builder for chaining.
*/
public Builder clearDetail() {
detail_ = getDefaultInstance().getDetail();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
* string detail = 2;
* @param value The bytes for detail to set.
* @return This builder for chaining.
*/
public Builder setDetailBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
detail_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private com.google.protobuf.Internal.IntList data_ = emptyIntList();
private void ensureDataIsMutable() {
if (!data_.isModifiable()) {
data_ = makeMutableCopy(data_);
}
bitField0_ |= 0x00000004;
}
/**
* repeated int32 data = 3;
* @return A list containing the data.
*/
public java.util.List
getDataList() {
data_.makeImmutable();
return data_;
}
/**
* repeated int32 data = 3;
* @return The count of data.
*/
public int getDataCount() {
return data_.size();
}
/**
* repeated int32 data = 3;
* @param index The index of the element to return.
* @return The data at the given index.
*/
public int getData(int index) {
return data_.getInt(index);
}
/**
* repeated int32 data = 3;
* @param index The index to set the value at.
* @param value The data to set.
* @return This builder for chaining.
*/
public Builder setData(
int index, int value) {
ensureDataIsMutable();
data_.setInt(index, value);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
* repeated int32 data = 3;
* @param value The data to add.
* @return This builder for chaining.
*/
public Builder addData(int value) {
ensureDataIsMutable();
data_.addInt(value);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
* repeated int32 data = 3;
* @param values The data to add.
* @return This builder for chaining.
*/
public Builder addAllData(
java.lang.Iterable extends java.lang.Integer> values) {
ensureDataIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, data_);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
* repeated int32 data = 3;
* @return This builder for chaining.
*/
public Builder clearData() {
data_ = emptyIntList();
bitField0_ = (bitField0_ & ~0x00000004);
onChanged();
return this;
}
// @@protoc_insertion_point(builder_scope:diozero.IntegerArrayResponse)
}
// @@protoc_insertion_point(class_scope:diozero.IntegerArrayResponse)
private static final com.diozero.remote.message.protobuf.IntegerArrayResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.diozero.remote.message.protobuf.IntegerArrayResponse();
}
public static com.diozero.remote.message.protobuf.IntegerArrayResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public IntegerArrayResponse 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.diozero.remote.message.protobuf.IntegerArrayResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy