Class BlockInfo
- Namespace
- Concordium.Grpc.V2
- Assembly
- Concordium.Sdk.dll
The response for GetBlockInfo.
public sealed class BlockInfo : IMessage<BlockInfo>, IEquatable<BlockInfo>, IDeepCloneable<BlockInfo>, IBufferMessage, IMessage
- Inheritance
-
BlockInfo
- Inherited Members
Constructors
BlockInfo()
public BlockInfo()
BlockInfo(BlockInfo)
public BlockInfo(BlockInfo other)
Parameters
other
BlockInfo
Fields
ArriveTimeFieldNumber
Field number for the "arrive_time" field.
public const int ArriveTimeFieldNumber = 8
Field Value
BakerFieldNumber
Field number for the "baker" field.
public const int BakerFieldNumber = 11
Field Value
EpochFieldNumber
Field number for the "epoch" field.
public const int EpochFieldNumber = 19
Field Value
EraBlockHeightFieldNumber
Field number for the "era_block_height" field.
public const int EraBlockHeightFieldNumber = 6
Field Value
FinalizedFieldNumber
Field number for the "finalized" field.
public const int FinalizedFieldNumber = 12
Field Value
GenesisIndexFieldNumber
Field number for the "genesis_index" field.
public const int GenesisIndexFieldNumber = 5
Field Value
HashFieldNumber
Field number for the "hash" field.
public const int HashFieldNumber = 1
Field Value
HeightFieldNumber
Field number for the "height" field.
public const int HeightFieldNumber = 2
Field Value
LastFinalizedBlockFieldNumber
Field number for the "last_finalized_block" field.
public const int LastFinalizedBlockFieldNumber = 4
Field Value
ParentBlockFieldNumber
Field number for the "parent_block" field.
public const int ParentBlockFieldNumber = 3
Field Value
ProtocolVersionFieldNumber
Field number for the "protocol_version" field.
public const int ProtocolVersionFieldNumber = 17
Field Value
ReceiveTimeFieldNumber
Field number for the "receive_time" field.
public const int ReceiveTimeFieldNumber = 7
Field Value
RoundFieldNumber
Field number for the "round" field.
public const int RoundFieldNumber = 18
Field Value
SlotNumberFieldNumber
Field number for the "slot_number" field.
public const int SlotNumberFieldNumber = 9
Field Value
SlotTimeFieldNumber
Field number for the "slot_time" field.
public const int SlotTimeFieldNumber = 10
Field Value
StateHashFieldNumber
Field number for the "state_hash" field.
public const int StateHashFieldNumber = 16
Field Value
TransactionCountFieldNumber
Field number for the "transaction_count" field.
public const int TransactionCountFieldNumber = 13
Field Value
TransactionsEnergyCostFieldNumber
Field number for the "transactions_energy_cost" field.
public const int TransactionsEnergyCostFieldNumber = 14
Field Value
TransactionsSizeFieldNumber
Field number for the "transactions_size" field.
public const int TransactionsSizeFieldNumber = 15
Field Value
Properties
ArriveTime
The time the block was verified.
public Timestamp ArriveTime { get; set; }
Property Value
Baker
The baker id of account baking this block. Not provided for a genesis block.
public BakerId Baker { get; set; }
Property Value
Descriptor
public static MessageDescriptor Descriptor { get; }
Property Value
- MessageDescriptor
Epoch
Block epoch. Present from protocol version 6.
public Epoch Epoch { get; set; }
Property Value
EraBlockHeight
The height of this block relative to the (re)genesis block of its era.
public BlockHeight EraBlockHeight { get; set; }
Property Value
Finalized
Whether the block is finalized.
public bool Finalized { get; set; }
Property Value
GenesisIndex
The genesis index for this block. This counts the number of protocol updates that have preceded this block, and defines the era of the block.
public GenesisIndex GenesisIndex { get; set; }
Property Value
Hash
Hash of the block.
public BlockHash Hash { get; set; }
Property Value
Height
Absolute height of the block, height 0 is the genesis block.
public AbsoluteBlockHeight Height { get; set; }
Property Value
LastFinalizedBlock
The last finalized block when this block was baked.
public BlockHash LastFinalizedBlock { get; set; }
Property Value
ParentBlock
The parent block hash. For a re-genesis block, this will be the terminal block of the previous chain. For the initial genesis block, this will be the hash of the block itself.
public BlockHash ParentBlock { get; set; }
Property Value
Parser
public static MessageParser<BlockInfo> Parser { get; }
Property Value
- MessageParser<BlockInfo>
ProtocolVersion
Protocol version to which the block belongs.
public ProtocolVersion ProtocolVersion { get; set; }
Property Value
ReceiveTime
The time the block was received.
public Timestamp ReceiveTime { get; set; }
Property Value
Round
Block round. Present from protocol version 6.
public Round Round { get; set; }
Property Value
SlotNumber
The slot number in which the block was baked. Present in protocol versions 1-5.
public Slot SlotNumber { get; set; }
Property Value
SlotTime
The time of the slot in which the block was baked.
public Timestamp SlotTime { get; set; }
Property Value
StateHash
The hash of the block state after this block.
public StateHash StateHash { get; set; }
Property Value
TransactionCount
The number of transactions in the block.
public uint TransactionCount { get; set; }
Property Value
TransactionsEnergyCost
The energy cost of the transactions in the block.
public Energy TransactionsEnergyCost { get; set; }
Property Value
TransactionsSize
The total byte size of all transactions in the block.
public uint TransactionsSize { get; set; }
Property Value
Methods
CalculateSize()
Calculates the size of this message in Protocol Buffer wire format, in bytes.
public int CalculateSize()
Returns
- int
The number of bytes required to write this message to a coded output stream.
Clone()
Creates a deep clone of this object.
public BlockInfo Clone()
Returns
- BlockInfo
A deep clone of this object.
Equals(BlockInfo)
Indicates whether the current object is equal to another object of the same type.
public bool Equals(BlockInfo other)
Parameters
other
BlockInfoAn object to compare with this object.
Returns
Equals(object)
Determines whether the specified object is equal to the current object.
public override bool Equals(object other)
Parameters
other
object
Returns
GetHashCode()
Serves as the default hash function.
public override int GetHashCode()
Returns
- int
A hash code for the current object.
MergeFrom(BlockInfo)
Merges the given message into this one.
public void MergeFrom(BlockInfo other)
Parameters
other
BlockInfo
Remarks
See the user guide for precise merge semantics.
MergeFrom(CodedInputStream)
Merges the data from the specified coded input stream with the current message.
public void MergeFrom(CodedInputStream input)
Parameters
input
CodedInputStream
Remarks
See the user guide for precise merge semantics.
ToString()
Returns a string that represents the current object.
public override string ToString()
Returns
- string
A string that represents the current object.
WriteTo(CodedOutputStream)
Writes the data to the given coded output stream.
public void WriteTo(CodedOutputStream output)
Parameters
output
CodedOutputStreamCoded output stream to write the data to. Must not be null.