Skip to content
Meshline
SDK 1.1.0 · TypeView source on GitHub

Developer guide · API index

Members on this page

Meshline.Sdk

Meshline.Interactions

IRelayRegistry Interface

Provides network identity and relay discovery from the application's registry integration.

public interface IRelayRegistry

Derived
↳ RpcRelayRegistry

Remarks

Return entries for the declared network context and preserve their registry status. Relay selection and transport validate whether an entry is usable for the requested operation.

Properties

IRelayRegistry.Context Property

The network reference and registry contract identifying this Meshline network.

Meshline.Models.NetworkContext Context { get; }

Property Value

NetworkContext

Methods

IRelayRegistry.GetRelayAsync(string, CancellationToken) Method

Looks up a relay registration by its canonical relay identifier.

System.Threading.Tasks.Task<Meshline.Models.Registry.RelayEntry?> GetRelayAsync(string relayId, System.Threading.CancellationToken cancellationToken=default(System.Threading.CancellationToken));

Parameters

relayId System.String

The relay's canonical lowercase Neo script-hash identifier.

cancellationToken System.Threading.CancellationToken

A token that can cancel the operation.

Returns

System.Threading.Tasks.Task<RelayEntry>
The matching registry entry, or null if the relay is not registered.

Exceptions

System.OperationCanceledException
The operation observes cancellation of cancellationToken.

IRelayRegistry.GetRelaysAsync(CancellationToken) Method

Enumerates the relay registrations available through the registry integration.

System.Collections.Generic.IAsyncEnumerable<Meshline.Models.Registry.RelayEntry> GetRelaysAsync(System.Threading.CancellationToken cancellationToken=default(System.Threading.CancellationToken));

Parameters

cancellationToken System.Threading.CancellationToken

A token that can cancel the operation.

Returns

System.Collections.Generic.IAsyncEnumerable<RelayEntry>
An asynchronous sequence of registry entries; entries may have inactive statuses.

Exceptions

System.OperationCanceledException
The operation observes cancellation of cancellationToken.