Class ConsensusNodeEndpoint
Represents a consensus node's network address, consisting of a node identifier and a gRPC endpoint URI for accessing the Hiero Network.
Implements
Inherited Members
Namespace: Hiero
Assembly: Hiero.dll
Syntax
[JsonConverter(typeof(ConsensusNodeEndpointConverter))]
public sealed record ConsensusNodeEndpoint : IEquatable<ConsensusNodeEndpoint>
Remarks
This class consists of both an EntityId representing the main node within the network and the gRPC URL for the network node where the public network endpoint is located. This class is immutable once created.
Constructors
| Edit this page View SourceConsensusNodeEndpoint(EntityId, Uri)
Public Constructor, a
ConsensusNodeEndpoint
is immutable after creation.
Declaration
public ConsensusNodeEndpoint(EntityId node, Uri uri)
Parameters
| Type | Name | Description |
|---|---|---|
| EntityId | node | Main Network Consensus Node's Address. |
| Uri | uri | The URL and port of the public Hiero Network Consensus Node's gRPC access point. A consensus node may actually have multiple gRPC endpoints mapped to the same wallet address (shard.realm.num). |
Properties
| Edit this page View SourceNode
The Network gRPC Consensus Node's Address, may only be [shard.realm.num] form.
Declaration
public EntityId Node { get; }
Property Value
| Type | Description |
|---|---|
| EntityId |
Uri
The URL and port of the public Hiero Network Consensus Node access point.
Declaration
public Uri Uri { get; }
Property Value
| Type | Description |
|---|---|
| Uri |
Methods
| Edit this page View SourceToString()
Returns a string representation of the Consensus Node ConsensusNodeEndpoint.
Declaration
public override string ToString()
Returns
| Type | Description |
|---|---|
| string | String Representation of the Consensus Node ConsensusNodeEndpoint |
Overrides
Operators
| Edit this page View Sourceimplicit operator EntityId(ConsensusNodeEndpoint)
Implicit operator for converting a ConsensusNodeEndpoint to an EntityId.
Declaration
public static implicit operator EntityId(ConsensusNodeEndpoint endpoint)
Parameters
| Type | Name | Description |
|---|---|---|
| ConsensusNodeEndpoint | endpoint | The ConsensusNodeEndpoint object containing the shard, realm and node number information to convert into an address object. |
Returns
| Type | Description |
|---|---|
| EntityId |