Show / Hide Table of Contents

Class BlockItem

A single item within a block stream block.

Inheritance
object
BlockItem
Implements
IEquatable<BlockItem>
Inherited Members
object.Equals(object)
object.Equals(object, object)
object.GetHashCode()
object.GetType()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: Hiero.BlockNode
Assembly: Hiero.dll
Syntax
[Experimental("HIERO001", UrlFormat = "https://github.com/bugbytesinc/Hiero/blob/main/docs/blocknode-client-plan.md")]
public sealed record BlockItem : IEquatable<BlockItem>
Remarks

This is a thin wrapper over the underlying block stream protobuf item. The Kind discriminator identifies the content; transaction bytes are promoted to SignedTransactionBytes because they are the most commonly consumed payload. All other content (transaction results, state changes, traces, …) is reachable losslessly through ToProtobuf() — the SDK deliberately does not domain-map those structures while the upstream block stream format remains in flux.

Properties

| Edit this page View Source

Kind

The kind of content this item carries.

Declaration
public BlockItemKind Kind { get; }
Property Value
Type Description
BlockItemKind
| Edit this page View Source

SignedTransactionBytes

The serialized signed transaction bytes, populated only when Kind is SignedTransaction; empty otherwise.

Declaration
public ReadOnlyMemory<byte> SignedTransactionBytes { get; }
Property Value
Type Description
ReadOnlyMemory<byte>

Methods

| Edit this page View Source

FromProtobuf(BlockItem)

Constructs a 
BlockItem

from a raw block stream protobuf item (round-trip counterpart of ToProtobuf(); also the entry point for constructing items to publish).

Declaration
public static BlockItem FromProtobuf(BlockItem item)
Parameters
Type Name Description
BlockItem item

The protobuf item to wrap.

Returns
Type Description
BlockItem
A 
BlockItem

exposing the protobuf's content.

Exceptions
Type Condition
ArgumentNullException

If the item is null.

| Edit this page View Source

ToProtobuf()

Returns the underlying block stream protobuf item — the lossless escape hatch to content the SDK does not domain-map (transaction results, state changes, traces, …).

Declaration
public BlockItem ToProtobuf()
Returns
Type Description
BlockItem

Implements

IEquatable<T>
  • Edit this page
  • View Source
In this article
Back to top .NET Client Library for Hiero Network and Hedera Hashgraph