com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of sdk-full Show documentation
Show all versions of sdk-full Show documentation
Hedera™ Hashgraph SDK for Java
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mirror/consensus_service.proto
// Protobuf Java Version: 3.25.3
package com.hedera.hashgraph.sdk.proto.mirror;
/**
* Protobuf type {@code com.hedera.mirror.api.proto.ConsensusTopicResponse}
*/
public final class ConsensusTopicResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:com.hedera.mirror.api.proto.ConsensusTopicResponse)
ConsensusTopicResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use ConsensusTopicResponse.newBuilder() to construct.
private ConsensusTopicResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private ConsensusTopicResponse() {
message_ = com.google.protobuf.ByteString.EMPTY;
runningHash_ = com.google.protobuf.ByteString.EMPTY;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new ConsensusTopicResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hedera.hashgraph.sdk.proto.mirror.ConsensusServiceOuterClass.internal_static_com_hedera_mirror_api_proto_ConsensusTopicResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hedera.hashgraph.sdk.proto.mirror.ConsensusServiceOuterClass.internal_static_com_hedera_mirror_api_proto_ConsensusTopicResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.class, com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.Builder.class);
}
private int bitField0_;
public static final int CONSENSUSTIMESTAMP_FIELD_NUMBER = 1;
private com.hedera.hashgraph.sdk.proto.Timestamp consensusTimestamp_;
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
* @return Whether the consensusTimestamp field is set.
*/
@java.lang.Override
public boolean hasConsensusTimestamp() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
* @return The consensusTimestamp.
*/
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.Timestamp getConsensusTimestamp() {
return consensusTimestamp_ == null ? com.hedera.hashgraph.sdk.proto.Timestamp.getDefaultInstance() : consensusTimestamp_;
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.TimestampOrBuilder getConsensusTimestampOrBuilder() {
return consensusTimestamp_ == null ? com.hedera.hashgraph.sdk.proto.Timestamp.getDefaultInstance() : consensusTimestamp_;
}
public static final int MESSAGE_FIELD_NUMBER = 2;
private com.google.protobuf.ByteString message_ = com.google.protobuf.ByteString.EMPTY;
/**
*
**
* The message body originally in the ConsensusSubmitMessageTransactionBody. Message size will
* be less than 6KiB.
*
*
* bytes message = 2;
* @return The message.
*/
@java.lang.Override
public com.google.protobuf.ByteString getMessage() {
return message_;
}
public static final int RUNNINGHASH_FIELD_NUMBER = 3;
private com.google.protobuf.ByteString runningHash_ = com.google.protobuf.ByteString.EMPTY;
/**
*
**
* The running hash (SHA384) of every message.
*
*
* bytes runningHash = 3;
* @return The runningHash.
*/
@java.lang.Override
public com.google.protobuf.ByteString getRunningHash() {
return runningHash_;
}
public static final int SEQUENCENUMBER_FIELD_NUMBER = 4;
private long sequenceNumber_ = 0L;
/**
*
**
* Starts at 1 for first submitted message. Incremented on each submitted message.
*
*
* uint64 sequenceNumber = 4;
* @return The sequenceNumber.
*/
@java.lang.Override
public long getSequenceNumber() {
return sequenceNumber_;
}
public static final int RUNNINGHASHVERSION_FIELD_NUMBER = 5;
private long runningHashVersion_ = 0L;
/**
*
**
* Version of the SHA-384 digest used to update the running hash.
*
*
* uint64 runningHashVersion = 5;
* @return The runningHashVersion.
*/
@java.lang.Override
public long getRunningHashVersion() {
return runningHashVersion_;
}
public static final int CHUNKINFO_FIELD_NUMBER = 6;
private com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo chunkInfo_;
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
* @return Whether the chunkInfo field is set.
*/
@java.lang.Override
public boolean hasChunkInfo() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
* @return The chunkInfo.
*/
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo getChunkInfo() {
return chunkInfo_ == null ? com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.getDefaultInstance() : chunkInfo_;
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfoOrBuilder getChunkInfoOrBuilder() {
return chunkInfo_ == null ? com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.getDefaultInstance() : chunkInfo_;
}
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, getConsensusTimestamp());
}
if (!message_.isEmpty()) {
output.writeBytes(2, message_);
}
if (!runningHash_.isEmpty()) {
output.writeBytes(3, runningHash_);
}
if (sequenceNumber_ != 0L) {
output.writeUInt64(4, sequenceNumber_);
}
if (runningHashVersion_ != 0L) {
output.writeUInt64(5, runningHashVersion_);
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeMessage(6, getChunkInfo());
}
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, getConsensusTimestamp());
}
if (!message_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(2, message_);
}
if (!runningHash_.isEmpty()) {
size += com.google.protobuf.CodedOutputStream
.computeBytesSize(3, runningHash_);
}
if (sequenceNumber_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeUInt64Size(4, sequenceNumber_);
}
if (runningHashVersion_ != 0L) {
size += com.google.protobuf.CodedOutputStream
.computeUInt64Size(5, runningHashVersion_);
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, getChunkInfo());
}
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.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse)) {
return super.equals(obj);
}
com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse other = (com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse) obj;
if (hasConsensusTimestamp() != other.hasConsensusTimestamp()) return false;
if (hasConsensusTimestamp()) {
if (!getConsensusTimestamp()
.equals(other.getConsensusTimestamp())) return false;
}
if (!getMessage()
.equals(other.getMessage())) return false;
if (!getRunningHash()
.equals(other.getRunningHash())) return false;
if (getSequenceNumber()
!= other.getSequenceNumber()) return false;
if (getRunningHashVersion()
!= other.getRunningHashVersion()) return false;
if (hasChunkInfo() != other.hasChunkInfo()) return false;
if (hasChunkInfo()) {
if (!getChunkInfo()
.equals(other.getChunkInfo())) 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 (hasConsensusTimestamp()) {
hash = (37 * hash) + CONSENSUSTIMESTAMP_FIELD_NUMBER;
hash = (53 * hash) + getConsensusTimestamp().hashCode();
}
hash = (37 * hash) + MESSAGE_FIELD_NUMBER;
hash = (53 * hash) + getMessage().hashCode();
hash = (37 * hash) + RUNNINGHASH_FIELD_NUMBER;
hash = (53 * hash) + getRunningHash().hashCode();
hash = (37 * hash) + SEQUENCENUMBER_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getSequenceNumber());
hash = (37 * hash) + RUNNINGHASHVERSION_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getRunningHashVersion());
if (hasChunkInfo()) {
hash = (37 * hash) + CHUNKINFO_FIELD_NUMBER;
hash = (53 * hash) + getChunkInfo().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse 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.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse 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.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse 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.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse 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.hedera.mirror.api.proto.ConsensusTopicResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:com.hedera.mirror.api.proto.ConsensusTopicResponse)
com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.hedera.hashgraph.sdk.proto.mirror.ConsensusServiceOuterClass.internal_static_com_hedera_mirror_api_proto_ConsensusTopicResponse_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.hedera.hashgraph.sdk.proto.mirror.ConsensusServiceOuterClass.internal_static_com_hedera_mirror_api_proto_ConsensusTopicResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.class, com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.Builder.class);
}
// Construct using com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getConsensusTimestampFieldBuilder();
getChunkInfoFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
consensusTimestamp_ = null;
if (consensusTimestampBuilder_ != null) {
consensusTimestampBuilder_.dispose();
consensusTimestampBuilder_ = null;
}
message_ = com.google.protobuf.ByteString.EMPTY;
runningHash_ = com.google.protobuf.ByteString.EMPTY;
sequenceNumber_ = 0L;
runningHashVersion_ = 0L;
chunkInfo_ = null;
if (chunkInfoBuilder_ != null) {
chunkInfoBuilder_.dispose();
chunkInfoBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.hedera.hashgraph.sdk.proto.mirror.ConsensusServiceOuterClass.internal_static_com_hedera_mirror_api_proto_ConsensusTopicResponse_descriptor;
}
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse getDefaultInstanceForType() {
return com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.getDefaultInstance();
}
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse build() {
com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse buildPartial() {
com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse result = new com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.consensusTimestamp_ = consensusTimestampBuilder_ == null
? consensusTimestamp_
: consensusTimestampBuilder_.build();
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.message_ = message_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.runningHash_ = runningHash_;
}
if (((from_bitField0_ & 0x00000008) != 0)) {
result.sequenceNumber_ = sequenceNumber_;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.runningHashVersion_ = runningHashVersion_;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
result.chunkInfo_ = chunkInfoBuilder_ == null
? chunkInfo_
: chunkInfoBuilder_.build();
to_bitField0_ |= 0x00000002;
}
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.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse) {
return mergeFrom((com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse other) {
if (other == com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse.getDefaultInstance()) return this;
if (other.hasConsensusTimestamp()) {
mergeConsensusTimestamp(other.getConsensusTimestamp());
}
if (other.getMessage() != com.google.protobuf.ByteString.EMPTY) {
setMessage(other.getMessage());
}
if (other.getRunningHash() != com.google.protobuf.ByteString.EMPTY) {
setRunningHash(other.getRunningHash());
}
if (other.getSequenceNumber() != 0L) {
setSequenceNumber(other.getSequenceNumber());
}
if (other.getRunningHashVersion() != 0L) {
setRunningHashVersion(other.getRunningHashVersion());
}
if (other.hasChunkInfo()) {
mergeChunkInfo(other.getChunkInfo());
}
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(
getConsensusTimestampFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
message_ = input.readBytes();
bitField0_ |= 0x00000002;
break;
} // case 18
case 26: {
runningHash_ = input.readBytes();
bitField0_ |= 0x00000004;
break;
} // case 26
case 32: {
sequenceNumber_ = input.readUInt64();
bitField0_ |= 0x00000008;
break;
} // case 32
case 40: {
runningHashVersion_ = input.readUInt64();
bitField0_ |= 0x00000010;
break;
} // case 40
case 50: {
input.readMessage(
getChunkInfoFieldBuilder().getBuilder(),
extensionRegistry);
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.hedera.hashgraph.sdk.proto.Timestamp consensusTimestamp_;
private com.google.protobuf.SingleFieldBuilderV3<
com.hedera.hashgraph.sdk.proto.Timestamp, com.hedera.hashgraph.sdk.proto.Timestamp.Builder, com.hedera.hashgraph.sdk.proto.TimestampOrBuilder> consensusTimestampBuilder_;
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
* @return Whether the consensusTimestamp field is set.
*/
public boolean hasConsensusTimestamp() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
* @return The consensusTimestamp.
*/
public com.hedera.hashgraph.sdk.proto.Timestamp getConsensusTimestamp() {
if (consensusTimestampBuilder_ == null) {
return consensusTimestamp_ == null ? com.hedera.hashgraph.sdk.proto.Timestamp.getDefaultInstance() : consensusTimestamp_;
} else {
return consensusTimestampBuilder_.getMessage();
}
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
public Builder setConsensusTimestamp(com.hedera.hashgraph.sdk.proto.Timestamp value) {
if (consensusTimestampBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
consensusTimestamp_ = value;
} else {
consensusTimestampBuilder_.setMessage(value);
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
public Builder setConsensusTimestamp(
com.hedera.hashgraph.sdk.proto.Timestamp.Builder builderForValue) {
if (consensusTimestampBuilder_ == null) {
consensusTimestamp_ = builderForValue.build();
} else {
consensusTimestampBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
public Builder mergeConsensusTimestamp(com.hedera.hashgraph.sdk.proto.Timestamp value) {
if (consensusTimestampBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0) &&
consensusTimestamp_ != null &&
consensusTimestamp_ != com.hedera.hashgraph.sdk.proto.Timestamp.getDefaultInstance()) {
getConsensusTimestampBuilder().mergeFrom(value);
} else {
consensusTimestamp_ = value;
}
} else {
consensusTimestampBuilder_.mergeFrom(value);
}
if (consensusTimestamp_ != null) {
bitField0_ |= 0x00000001;
onChanged();
}
return this;
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
public Builder clearConsensusTimestamp() {
bitField0_ = (bitField0_ & ~0x00000001);
consensusTimestamp_ = null;
if (consensusTimestampBuilder_ != null) {
consensusTimestampBuilder_.dispose();
consensusTimestampBuilder_ = null;
}
onChanged();
return this;
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
public com.hedera.hashgraph.sdk.proto.Timestamp.Builder getConsensusTimestampBuilder() {
bitField0_ |= 0x00000001;
onChanged();
return getConsensusTimestampFieldBuilder().getBuilder();
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
public com.hedera.hashgraph.sdk.proto.TimestampOrBuilder getConsensusTimestampOrBuilder() {
if (consensusTimestampBuilder_ != null) {
return consensusTimestampBuilder_.getMessageOrBuilder();
} else {
return consensusTimestamp_ == null ?
com.hedera.hashgraph.sdk.proto.Timestamp.getDefaultInstance() : consensusTimestamp_;
}
}
/**
*
**
* The time at which the transaction reached consensus
*
*
* .proto.Timestamp consensusTimestamp = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.hedera.hashgraph.sdk.proto.Timestamp, com.hedera.hashgraph.sdk.proto.Timestamp.Builder, com.hedera.hashgraph.sdk.proto.TimestampOrBuilder>
getConsensusTimestampFieldBuilder() {
if (consensusTimestampBuilder_ == null) {
consensusTimestampBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.hedera.hashgraph.sdk.proto.Timestamp, com.hedera.hashgraph.sdk.proto.Timestamp.Builder, com.hedera.hashgraph.sdk.proto.TimestampOrBuilder>(
getConsensusTimestamp(),
getParentForChildren(),
isClean());
consensusTimestamp_ = null;
}
return consensusTimestampBuilder_;
}
private com.google.protobuf.ByteString message_ = com.google.protobuf.ByteString.EMPTY;
/**
*
**
* The message body originally in the ConsensusSubmitMessageTransactionBody. Message size will
* be less than 6KiB.
*
*
* bytes message = 2;
* @return The message.
*/
@java.lang.Override
public com.google.protobuf.ByteString getMessage() {
return message_;
}
/**
*
**
* The message body originally in the ConsensusSubmitMessageTransactionBody. Message size will
* be less than 6KiB.
*
*
* bytes message = 2;
* @param value The message to set.
* @return This builder for chaining.
*/
public Builder setMessage(com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
message_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
**
* The message body originally in the ConsensusSubmitMessageTransactionBody. Message size will
* be less than 6KiB.
*
*
* bytes message = 2;
* @return This builder for chaining.
*/
public Builder clearMessage() {
bitField0_ = (bitField0_ & ~0x00000002);
message_ = getDefaultInstance().getMessage();
onChanged();
return this;
}
private com.google.protobuf.ByteString runningHash_ = com.google.protobuf.ByteString.EMPTY;
/**
*
**
* The running hash (SHA384) of every message.
*
*
* bytes runningHash = 3;
* @return The runningHash.
*/
@java.lang.Override
public com.google.protobuf.ByteString getRunningHash() {
return runningHash_;
}
/**
*
**
* The running hash (SHA384) of every message.
*
*
* bytes runningHash = 3;
* @param value The runningHash to set.
* @return This builder for chaining.
*/
public Builder setRunningHash(com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
runningHash_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
**
* The running hash (SHA384) of every message.
*
*
* bytes runningHash = 3;
* @return This builder for chaining.
*/
public Builder clearRunningHash() {
bitField0_ = (bitField0_ & ~0x00000004);
runningHash_ = getDefaultInstance().getRunningHash();
onChanged();
return this;
}
private long sequenceNumber_ ;
/**
*
**
* Starts at 1 for first submitted message. Incremented on each submitted message.
*
*
* uint64 sequenceNumber = 4;
* @return The sequenceNumber.
*/
@java.lang.Override
public long getSequenceNumber() {
return sequenceNumber_;
}
/**
*
**
* Starts at 1 for first submitted message. Incremented on each submitted message.
*
*
* uint64 sequenceNumber = 4;
* @param value The sequenceNumber to set.
* @return This builder for chaining.
*/
public Builder setSequenceNumber(long value) {
sequenceNumber_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
**
* Starts at 1 for first submitted message. Incremented on each submitted message.
*
*
* uint64 sequenceNumber = 4;
* @return This builder for chaining.
*/
public Builder clearSequenceNumber() {
bitField0_ = (bitField0_ & ~0x00000008);
sequenceNumber_ = 0L;
onChanged();
return this;
}
private long runningHashVersion_ ;
/**
*
**
* Version of the SHA-384 digest used to update the running hash.
*
*
* uint64 runningHashVersion = 5;
* @return The runningHashVersion.
*/
@java.lang.Override
public long getRunningHashVersion() {
return runningHashVersion_;
}
/**
*
**
* Version of the SHA-384 digest used to update the running hash.
*
*
* uint64 runningHashVersion = 5;
* @param value The runningHashVersion to set.
* @return This builder for chaining.
*/
public Builder setRunningHashVersion(long value) {
runningHashVersion_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
**
* Version of the SHA-384 digest used to update the running hash.
*
*
* uint64 runningHashVersion = 5;
* @return This builder for chaining.
*/
public Builder clearRunningHashVersion() {
bitField0_ = (bitField0_ & ~0x00000010);
runningHashVersion_ = 0L;
onChanged();
return this;
}
private com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo chunkInfo_;
private com.google.protobuf.SingleFieldBuilderV3<
com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo, com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.Builder, com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfoOrBuilder> chunkInfoBuilder_;
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
* @return Whether the chunkInfo field is set.
*/
public boolean hasChunkInfo() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
* @return The chunkInfo.
*/
public com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo getChunkInfo() {
if (chunkInfoBuilder_ == null) {
return chunkInfo_ == null ? com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.getDefaultInstance() : chunkInfo_;
} else {
return chunkInfoBuilder_.getMessage();
}
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
public Builder setChunkInfo(com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo value) {
if (chunkInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
chunkInfo_ = value;
} else {
chunkInfoBuilder_.setMessage(value);
}
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
public Builder setChunkInfo(
com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.Builder builderForValue) {
if (chunkInfoBuilder_ == null) {
chunkInfo_ = builderForValue.build();
} else {
chunkInfoBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
public Builder mergeChunkInfo(com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo value) {
if (chunkInfoBuilder_ == null) {
if (((bitField0_ & 0x00000020) != 0) &&
chunkInfo_ != null &&
chunkInfo_ != com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.getDefaultInstance()) {
getChunkInfoBuilder().mergeFrom(value);
} else {
chunkInfo_ = value;
}
} else {
chunkInfoBuilder_.mergeFrom(value);
}
if (chunkInfo_ != null) {
bitField0_ |= 0x00000020;
onChanged();
}
return this;
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
public Builder clearChunkInfo() {
bitField0_ = (bitField0_ & ~0x00000020);
chunkInfo_ = null;
if (chunkInfoBuilder_ != null) {
chunkInfoBuilder_.dispose();
chunkInfoBuilder_ = null;
}
onChanged();
return this;
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
public com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.Builder getChunkInfoBuilder() {
bitField0_ |= 0x00000020;
onChanged();
return getChunkInfoFieldBuilder().getBuilder();
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
public com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfoOrBuilder getChunkInfoOrBuilder() {
if (chunkInfoBuilder_ != null) {
return chunkInfoBuilder_.getMessageOrBuilder();
} else {
return chunkInfo_ == null ?
com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.getDefaultInstance() : chunkInfo_;
}
}
/**
*
**
* Optional information of the current chunk in a fragmented message.
*
*
* .proto.ConsensusMessageChunkInfo chunkInfo = 6;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo, com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.Builder, com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfoOrBuilder>
getChunkInfoFieldBuilder() {
if (chunkInfoBuilder_ == null) {
chunkInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo, com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfo.Builder, com.hedera.hashgraph.sdk.proto.ConsensusMessageChunkInfoOrBuilder>(
getChunkInfo(),
getParentForChildren(),
isClean());
chunkInfo_ = null;
}
return chunkInfoBuilder_;
}
@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.hedera.mirror.api.proto.ConsensusTopicResponse)
}
// @@protoc_insertion_point(class_scope:com.hedera.mirror.api.proto.ConsensusTopicResponse)
private static final com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse();
}
public static com.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public ConsensusTopicResponse 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.hedera.hashgraph.sdk.proto.mirror.ConsensusTopicResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}