All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.hederahashgraph.api.proto.java.BlockStreamInfo Maven / Gradle / Ivy

There is a newer version: 0.54.0
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: state/blockstream/block_stream_info.proto

package com.hederahashgraph.api.proto.java;

/**
 * 
 **
 * A message stored in state to maintain block stream parameters.<br/>
 * Nodes use this information for three purposes.
 * 1. To maintain hash chain continuity at restart and reconnect boundaries.
 * 1. To store historical hashes for implementation of the EVM `BLOCKHASH`
 *    and `PREVRANDAO` opcodes.
 * 1. To track the amount of consensus time that has passed between blocks.
 * This value MUST be updated for every block.<br/>
 * This value MUST be transmitted in the "state changes" section of
 * _each_ block, but MUST be updated at the beginning of the _next_ block.<br/>
 * This value SHALL contain the block hash up to, and including, the
 * immediately prior completed block.
 * 
* * Protobuf type {@code com.hedera.hapi.node.state.blockstream.BlockStreamInfo} */ public final class BlockStreamInfo extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:com.hedera.hapi.node.state.blockstream.BlockStreamInfo) BlockStreamInfoOrBuilder { private static final long serialVersionUID = 0L; // Use BlockStreamInfo.newBuilder() to construct. private BlockStreamInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private BlockStreamInfo() { trailingOutputHashes_ = com.google.protobuf.ByteString.EMPTY; trailingBlockHashes_ = com.google.protobuf.ByteString.EMPTY; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new BlockStreamInfo(); } @java.lang.Override public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } private BlockStreamInfo( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } 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: { blockNumber_ = input.readUInt64(); break; } case 18: { com.hederahashgraph.api.proto.java.Timestamp.Builder subBuilder = null; if (blockTime_ != null) { subBuilder = blockTime_.toBuilder(); } blockTime_ = input.readMessage(com.hederahashgraph.api.proto.java.Timestamp.parser(), extensionRegistry); if (subBuilder != null) { subBuilder.mergeFrom(blockTime_); blockTime_ = subBuilder.buildPartial(); } break; } case 26: { trailingOutputHashes_ = input.readBytes(); break; } case 34: { trailingBlockHashes_ = input.readBytes(); 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.hederahashgraph.api.proto.java.BlockStreamInfoOuterClass.internal_static_com_hedera_hapi_node_state_blockstream_BlockStreamInfo_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.hederahashgraph.api.proto.java.BlockStreamInfoOuterClass.internal_static_com_hedera_hapi_node_state_blockstream_BlockStreamInfo_fieldAccessorTable .ensureFieldAccessorsInitialized( com.hederahashgraph.api.proto.java.BlockStreamInfo.class, com.hederahashgraph.api.proto.java.BlockStreamInfo.Builder.class); } public static final int BLOCK_NUMBER_FIELD_NUMBER = 1; private long blockNumber_; /** *
   **
   * A block number.<br/>
   * This is the current block number.
   * 
* * uint64 block_number = 1; * @return The blockNumber. */ @java.lang.Override public long getBlockNumber() { return blockNumber_; } public static final int BLOCK_TIME_FIELD_NUMBER = 2; private com.hederahashgraph.api.proto.java.Timestamp blockTime_; /** *
   **
   * A consensus time for the current block.<br/>
   * This is the _first_ consensus time in the current block, and
   * is used to determine if this block was the first across an
   * important boundary in consensus time, such as UTC midnight.
   * This may also be used to purge entities expiring between the last
   * block time and this time.
   * 
* * .proto.Timestamp block_time = 2; * @return Whether the blockTime field is set. */ @java.lang.Override public boolean hasBlockTime() { return blockTime_ != null; } /** *
   **
   * A consensus time for the current block.<br/>
   * This is the _first_ consensus time in the current block, and
   * is used to determine if this block was the first across an
   * important boundary in consensus time, such as UTC midnight.
   * This may also be used to purge entities expiring between the last
   * block time and this time.
   * 
* * .proto.Timestamp block_time = 2; * @return The blockTime. */ @java.lang.Override public com.hederahashgraph.api.proto.java.Timestamp getBlockTime() { return blockTime_ == null ? com.hederahashgraph.api.proto.java.Timestamp.getDefaultInstance() : blockTime_; } /** *
   **
   * A consensus time for the current block.<br/>
   * This is the _first_ consensus time in the current block, and
   * is used to determine if this block was the first across an
   * important boundary in consensus time, such as UTC midnight.
   * This may also be used to purge entities expiring between the last
   * block time and this time.
   * 
* * .proto.Timestamp block_time = 2; */ @java.lang.Override public com.hederahashgraph.api.proto.java.TimestampOrBuilder getBlockTimeOrBuilder() { return getBlockTime(); } public static final int TRAILING_OUTPUT_HASHES_FIELD_NUMBER = 3; private com.google.protobuf.ByteString trailingOutputHashes_; /** *
   **
   * A concatenation of hash values.<br/>
   * This combines several trailing output block item hashes and
   * is used as a seed value for a pseudo-random number generator.<br/>
   * This is also requiried to implement the EVM `PREVRANDAO` opcode.
   * 
* * bytes trailing_output_hashes = 3; * @return The trailingOutputHashes. */ @java.lang.Override public com.google.protobuf.ByteString getTrailingOutputHashes() { return trailingOutputHashes_; } public static final int TRAILING_BLOCK_HASHES_FIELD_NUMBER = 4; private com.google.protobuf.ByteString trailingBlockHashes_; /** *
   **
   * A concatenation of hash values.<br/>
   * This field combines up to 256 trailing block hashes.
   * <p>
   * If this message is for block number N, then the earliest available
   * hash SHALL be for block number N-256.<br/>
   * The latest available hash SHALL be for block N-1.<br/>
   * This is REQUIRED to implement the EVM `BLOCKHASH` opcode.
   * 
* * bytes trailing_block_hashes = 4; * @return The trailingBlockHashes. */ @java.lang.Override public com.google.protobuf.ByteString getTrailingBlockHashes() { return trailingBlockHashes_; } 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 (blockNumber_ != 0L) { output.writeUInt64(1, blockNumber_); } if (blockTime_ != null) { output.writeMessage(2, getBlockTime()); } if (!trailingOutputHashes_.isEmpty()) { output.writeBytes(3, trailingOutputHashes_); } if (!trailingBlockHashes_.isEmpty()) { output.writeBytes(4, trailingBlockHashes_); } unknownFields.writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (blockNumber_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeUInt64Size(1, blockNumber_); } if (blockTime_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, getBlockTime()); } if (!trailingOutputHashes_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(3, trailingOutputHashes_); } if (!trailingBlockHashes_.isEmpty()) { size += com.google.protobuf.CodedOutputStream .computeBytesSize(4, trailingBlockHashes_); } 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.hederahashgraph.api.proto.java.BlockStreamInfo)) { return super.equals(obj); } com.hederahashgraph.api.proto.java.BlockStreamInfo other = (com.hederahashgraph.api.proto.java.BlockStreamInfo) obj; if (getBlockNumber() != other.getBlockNumber()) return false; if (hasBlockTime() != other.hasBlockTime()) return false; if (hasBlockTime()) { if (!getBlockTime() .equals(other.getBlockTime())) return false; } if (!getTrailingOutputHashes() .equals(other.getTrailingOutputHashes())) return false; if (!getTrailingBlockHashes() .equals(other.getTrailingBlockHashes())) 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) + BLOCK_NUMBER_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getBlockNumber()); if (hasBlockTime()) { hash = (37 * hash) + BLOCK_TIME_FIELD_NUMBER; hash = (53 * hash) + getBlockTime().hashCode(); } hash = (37 * hash) + TRAILING_OUTPUT_HASHES_FIELD_NUMBER; hash = (53 * hash) + getTrailingOutputHashes().hashCode(); hash = (37 * hash) + TRAILING_BLOCK_HASHES_FIELD_NUMBER; hash = (53 * hash) + getTrailingBlockHashes().hashCode(); hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo 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.hederahashgraph.api.proto.java.BlockStreamInfo parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo 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.hederahashgraph.api.proto.java.BlockStreamInfo parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo 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.hederahashgraph.api.proto.java.BlockStreamInfo 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; } /** *
   **
   * A message stored in state to maintain block stream parameters.<br/>
   * Nodes use this information for three purposes.
   * 1. To maintain hash chain continuity at restart and reconnect boundaries.
   * 1. To store historical hashes for implementation of the EVM `BLOCKHASH`
   *    and `PREVRANDAO` opcodes.
   * 1. To track the amount of consensus time that has passed between blocks.
   * This value MUST be updated for every block.<br/>
   * This value MUST be transmitted in the "state changes" section of
   * _each_ block, but MUST be updated at the beginning of the _next_ block.<br/>
   * This value SHALL contain the block hash up to, and including, the
   * immediately prior completed block.
   * 
* * Protobuf type {@code com.hedera.hapi.node.state.blockstream.BlockStreamInfo} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:com.hedera.hapi.node.state.blockstream.BlockStreamInfo) com.hederahashgraph.api.proto.java.BlockStreamInfoOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.hederahashgraph.api.proto.java.BlockStreamInfoOuterClass.internal_static_com_hedera_hapi_node_state_blockstream_BlockStreamInfo_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.hederahashgraph.api.proto.java.BlockStreamInfoOuterClass.internal_static_com_hedera_hapi_node_state_blockstream_BlockStreamInfo_fieldAccessorTable .ensureFieldAccessorsInitialized( com.hederahashgraph.api.proto.java.BlockStreamInfo.class, com.hederahashgraph.api.proto.java.BlockStreamInfo.Builder.class); } // Construct using com.hederahashgraph.api.proto.java.BlockStreamInfo.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(); blockNumber_ = 0L; if (blockTimeBuilder_ == null) { blockTime_ = null; } else { blockTime_ = null; blockTimeBuilder_ = null; } trailingOutputHashes_ = com.google.protobuf.ByteString.EMPTY; trailingBlockHashes_ = com.google.protobuf.ByteString.EMPTY; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.hederahashgraph.api.proto.java.BlockStreamInfoOuterClass.internal_static_com_hedera_hapi_node_state_blockstream_BlockStreamInfo_descriptor; } @java.lang.Override public com.hederahashgraph.api.proto.java.BlockStreamInfo getDefaultInstanceForType() { return com.hederahashgraph.api.proto.java.BlockStreamInfo.getDefaultInstance(); } @java.lang.Override public com.hederahashgraph.api.proto.java.BlockStreamInfo build() { com.hederahashgraph.api.proto.java.BlockStreamInfo result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.hederahashgraph.api.proto.java.BlockStreamInfo buildPartial() { com.hederahashgraph.api.proto.java.BlockStreamInfo result = new com.hederahashgraph.api.proto.java.BlockStreamInfo(this); result.blockNumber_ = blockNumber_; if (blockTimeBuilder_ == null) { result.blockTime_ = blockTime_; } else { result.blockTime_ = blockTimeBuilder_.build(); } result.trailingOutputHashes_ = trailingOutputHashes_; result.trailingBlockHashes_ = trailingBlockHashes_; 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.hederahashgraph.api.proto.java.BlockStreamInfo) { return mergeFrom((com.hederahashgraph.api.proto.java.BlockStreamInfo)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.hederahashgraph.api.proto.java.BlockStreamInfo other) { if (other == com.hederahashgraph.api.proto.java.BlockStreamInfo.getDefaultInstance()) return this; if (other.getBlockNumber() != 0L) { setBlockNumber(other.getBlockNumber()); } if (other.hasBlockTime()) { mergeBlockTime(other.getBlockTime()); } if (other.getTrailingOutputHashes() != com.google.protobuf.ByteString.EMPTY) { setTrailingOutputHashes(other.getTrailingOutputHashes()); } if (other.getTrailingBlockHashes() != com.google.protobuf.ByteString.EMPTY) { setTrailingBlockHashes(other.getTrailingBlockHashes()); } 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.hederahashgraph.api.proto.java.BlockStreamInfo parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { parsedMessage = (com.hederahashgraph.api.proto.java.BlockStreamInfo) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { mergeFrom(parsedMessage); } } return this; } private long blockNumber_ ; /** *
     **
     * A block number.<br/>
     * This is the current block number.
     * 
* * uint64 block_number = 1; * @return The blockNumber. */ @java.lang.Override public long getBlockNumber() { return blockNumber_; } /** *
     **
     * A block number.<br/>
     * This is the current block number.
     * 
* * uint64 block_number = 1; * @param value The blockNumber to set. * @return This builder for chaining. */ public Builder setBlockNumber(long value) { blockNumber_ = value; onChanged(); return this; } /** *
     **
     * A block number.<br/>
     * This is the current block number.
     * 
* * uint64 block_number = 1; * @return This builder for chaining. */ public Builder clearBlockNumber() { blockNumber_ = 0L; onChanged(); return this; } private com.hederahashgraph.api.proto.java.Timestamp blockTime_; private com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.Timestamp, com.hederahashgraph.api.proto.java.Timestamp.Builder, com.hederahashgraph.api.proto.java.TimestampOrBuilder> blockTimeBuilder_; /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; * @return Whether the blockTime field is set. */ public boolean hasBlockTime() { return blockTimeBuilder_ != null || blockTime_ != null; } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; * @return The blockTime. */ public com.hederahashgraph.api.proto.java.Timestamp getBlockTime() { if (blockTimeBuilder_ == null) { return blockTime_ == null ? com.hederahashgraph.api.proto.java.Timestamp.getDefaultInstance() : blockTime_; } else { return blockTimeBuilder_.getMessage(); } } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ public Builder setBlockTime(com.hederahashgraph.api.proto.java.Timestamp value) { if (blockTimeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } blockTime_ = value; onChanged(); } else { blockTimeBuilder_.setMessage(value); } return this; } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ public Builder setBlockTime( com.hederahashgraph.api.proto.java.Timestamp.Builder builderForValue) { if (blockTimeBuilder_ == null) { blockTime_ = builderForValue.build(); onChanged(); } else { blockTimeBuilder_.setMessage(builderForValue.build()); } return this; } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ public Builder mergeBlockTime(com.hederahashgraph.api.proto.java.Timestamp value) { if (blockTimeBuilder_ == null) { if (blockTime_ != null) { blockTime_ = com.hederahashgraph.api.proto.java.Timestamp.newBuilder(blockTime_).mergeFrom(value).buildPartial(); } else { blockTime_ = value; } onChanged(); } else { blockTimeBuilder_.mergeFrom(value); } return this; } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ public Builder clearBlockTime() { if (blockTimeBuilder_ == null) { blockTime_ = null; onChanged(); } else { blockTime_ = null; blockTimeBuilder_ = null; } return this; } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ public com.hederahashgraph.api.proto.java.Timestamp.Builder getBlockTimeBuilder() { onChanged(); return getBlockTimeFieldBuilder().getBuilder(); } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ public com.hederahashgraph.api.proto.java.TimestampOrBuilder getBlockTimeOrBuilder() { if (blockTimeBuilder_ != null) { return blockTimeBuilder_.getMessageOrBuilder(); } else { return blockTime_ == null ? com.hederahashgraph.api.proto.java.Timestamp.getDefaultInstance() : blockTime_; } } /** *
     **
     * A consensus time for the current block.<br/>
     * This is the _first_ consensus time in the current block, and
     * is used to determine if this block was the first across an
     * important boundary in consensus time, such as UTC midnight.
     * This may also be used to purge entities expiring between the last
     * block time and this time.
     * 
* * .proto.Timestamp block_time = 2; */ private com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.Timestamp, com.hederahashgraph.api.proto.java.Timestamp.Builder, com.hederahashgraph.api.proto.java.TimestampOrBuilder> getBlockTimeFieldBuilder() { if (blockTimeBuilder_ == null) { blockTimeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.hederahashgraph.api.proto.java.Timestamp, com.hederahashgraph.api.proto.java.Timestamp.Builder, com.hederahashgraph.api.proto.java.TimestampOrBuilder>( getBlockTime(), getParentForChildren(), isClean()); blockTime_ = null; } return blockTimeBuilder_; } private com.google.protobuf.ByteString trailingOutputHashes_ = com.google.protobuf.ByteString.EMPTY; /** *
     **
     * A concatenation of hash values.<br/>
     * This combines several trailing output block item hashes and
     * is used as a seed value for a pseudo-random number generator.<br/>
     * This is also requiried to implement the EVM `PREVRANDAO` opcode.
     * 
* * bytes trailing_output_hashes = 3; * @return The trailingOutputHashes. */ @java.lang.Override public com.google.protobuf.ByteString getTrailingOutputHashes() { return trailingOutputHashes_; } /** *
     **
     * A concatenation of hash values.<br/>
     * This combines several trailing output block item hashes and
     * is used as a seed value for a pseudo-random number generator.<br/>
     * This is also requiried to implement the EVM `PREVRANDAO` opcode.
     * 
* * bytes trailing_output_hashes = 3; * @param value The trailingOutputHashes to set. * @return This builder for chaining. */ public Builder setTrailingOutputHashes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } trailingOutputHashes_ = value; onChanged(); return this; } /** *
     **
     * A concatenation of hash values.<br/>
     * This combines several trailing output block item hashes and
     * is used as a seed value for a pseudo-random number generator.<br/>
     * This is also requiried to implement the EVM `PREVRANDAO` opcode.
     * 
* * bytes trailing_output_hashes = 3; * @return This builder for chaining. */ public Builder clearTrailingOutputHashes() { trailingOutputHashes_ = getDefaultInstance().getTrailingOutputHashes(); onChanged(); return this; } private com.google.protobuf.ByteString trailingBlockHashes_ = com.google.protobuf.ByteString.EMPTY; /** *
     **
     * A concatenation of hash values.<br/>
     * This field combines up to 256 trailing block hashes.
     * <p>
     * If this message is for block number N, then the earliest available
     * hash SHALL be for block number N-256.<br/>
     * The latest available hash SHALL be for block N-1.<br/>
     * This is REQUIRED to implement the EVM `BLOCKHASH` opcode.
     * 
* * bytes trailing_block_hashes = 4; * @return The trailingBlockHashes. */ @java.lang.Override public com.google.protobuf.ByteString getTrailingBlockHashes() { return trailingBlockHashes_; } /** *
     **
     * A concatenation of hash values.<br/>
     * This field combines up to 256 trailing block hashes.
     * <p>
     * If this message is for block number N, then the earliest available
     * hash SHALL be for block number N-256.<br/>
     * The latest available hash SHALL be for block N-1.<br/>
     * This is REQUIRED to implement the EVM `BLOCKHASH` opcode.
     * 
* * bytes trailing_block_hashes = 4; * @param value The trailingBlockHashes to set. * @return This builder for chaining. */ public Builder setTrailingBlockHashes(com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } trailingBlockHashes_ = value; onChanged(); return this; } /** *
     **
     * A concatenation of hash values.<br/>
     * This field combines up to 256 trailing block hashes.
     * <p>
     * If this message is for block number N, then the earliest available
     * hash SHALL be for block number N-256.<br/>
     * The latest available hash SHALL be for block N-1.<br/>
     * This is REQUIRED to implement the EVM `BLOCKHASH` opcode.
     * 
* * bytes trailing_block_hashes = 4; * @return This builder for chaining. */ public Builder clearTrailingBlockHashes() { trailingBlockHashes_ = getDefaultInstance().getTrailingBlockHashes(); 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.hedera.hapi.node.state.blockstream.BlockStreamInfo) } // @@protoc_insertion_point(class_scope:com.hedera.hapi.node.state.blockstream.BlockStreamInfo) private static final com.hederahashgraph.api.proto.java.BlockStreamInfo DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.hederahashgraph.api.proto.java.BlockStreamInfo(); } public static com.hederahashgraph.api.proto.java.BlockStreamInfo getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public BlockStreamInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return new BlockStreamInfo(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.hederahashgraph.api.proto.java.BlockStreamInfo getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy