Show / Hide Table of Contents

Class LedgerStreamResponse

This response mirrors the LedgerStream, except it does NOT include the 'type' nor 'txn_count' fields.

Inheritance
object
BaseResponse
LedgerStreamResponse
Inherited Members
BaseResponse.RawId
BaseResponse.Status
BaseResponse.Type
BaseResponse.RawResult
BaseResponse.Warning
BaseResponse.Warnings
BaseResponse.Forwarded
BaseResponse.ApiVersion
Namespace: Xrpl.Models.Methods
Assembly: Xrpl.dll
Syntax
public class LedgerStreamResponse : BaseResponse
Remarks

Models the subscribe command's own synchronous reply when the client subscribes to the ledger stream (rippled NetworkOpsImp::subLedger), a different code path from the async ledgerClosed push that LedgerStream models. There, ledger_index/reserve_base/reserve_inc (with ledger_hash, ledger_time and fee_base) are all gated on ledgerMaster_.getValidatedLedger() returning non-null - if the node has no validated ledger yet, the initial reply omits every one of them.

Properties

| Edit this page View Source

FeeBase

The reference transaction cost as of this ledger version, in drops of XRP.
If this ledger version includes a SetFee pseudo-transaction the new transaction cost applies starting with the following ledger version.

Declaration
[JsonPropertyName("fee_base")]
public uint? FeeBase { get; set; }
Property Value
Type Description
uint?
Remarks

See LedgerIndex remarks - same conditional gate.

| Edit this page View Source

FeeRef

The reference transaction cost in "fee units".

Declaration
[JsonPropertyName("fee_ref")]
public uint? FeeRef { get; set; }
Property Value
Type Description
uint?
Remarks

Doubly conditional in NetworkOpsImp::subLedger: inside the getValidatedLedger() gate AND only when the XRPFees amendment is disabled. Since that amendment is active on mainnet, a current node never sends this field.

| Edit this page View Source

LedgerHash

The identifying hash of the ledger version that was closed.

Declaration
[JsonPropertyName("ledger_hash")]
public string LedgerHash { get; set; }
Property Value
Type Description
string
| Edit this page View Source

LedgerIndex

The ledger index of the ledger that was closed.

Declaration
[JsonPropertyName("ledger_index")]
public ulong? LedgerIndex { get; set; }
Property Value
Type Description
ulong?
Remarks

rippled's NetworkOpsImp::subLedger only sets this (with ledger_hash, reserve_base and reserve_inc below) when ledgerMaster_.getValidatedLedger() returns a ledger; a node with no validated ledger yet omits it from the initial subscribe reply.

| Edit this page View Source

LedgerTime

The time this ledger was closed, in seconds since the Ripple Epoch

Declaration
[JsonPropertyName("ledger_time")]
public ulong? LedgerTime { get; set; }
Property Value
Type Description
ulong?
Remarks

See LedgerIndex remarks - same conditional gate.

| Edit this page View Source

ReserveBase

The minimum reserve, in drops of XRP, that is required for an account.
If this ledger version includes a SetFee pseudo-transaction the new base reserve applies starting with the following ledger version.

Declaration
[JsonPropertyName("reserve_base")]
public uint? ReserveBase { get; set; }
Property Value
Type Description
uint?
Remarks

See LedgerIndex remarks - same conditional gate.

| Edit this page View Source

ReserveInc

The owner reserve for each object an account owns in the ledger, in drops of XRP.
If the ledger includes a SetFee pseudo-transaction the new owner reserve applies after this ledger.

Declaration
[JsonPropertyName("reserve_inc")]
public uint? ReserveInc { get; set; }
Property Value
Type Description
uint?
Remarks

See LedgerIndex remarks - same conditional gate.

| Edit this page View Source

TxnCount

Number of new transactions included in this ledger version.

Declaration
[JsonPropertyName("txn_count")]
public uint? TxnCount { get; set; }
Property Value
Type Description
uint?
Remarks

Never sent on this path at all: NetworkOpsImp::subLedger emits no txn_count, which is what this type's own summary says. Only the asynchronous ledgerClosed push (LedgerStream) carries it.

| Edit this page View Source

UnknownFields

Members of the subscribe reply's result that no declared property claims

  • for example network_id, which NetworkOpsImp::subLedger sets unconditionally (NetworkOPs.cpp) alongside ledger_hash/ledger_index. BaseResponse carries no capture of its own (its id/result members are byte-range slices, not parsed values), so this class declares one directly rather than inheriting it - mirroring UnknownFields for the RPC-result family.
Declaration
[JsonExtensionData]
public Dictionary<string, JsonElement> UnknownFields { get; set; }
Property Value
Type Description
Dictionary<string, JsonElement>
| Edit this page View Source

ValidatedLedgers

(May be omitted) Range of ledgers that the server has available.
This may be a disjoint sequence such as 24900901-24900984,24901116-24901158.
This field is not returned if the server is not connected to the network, or if it is connected but has not yet obtained a ledger from the network.

Declaration
[JsonPropertyName("validated_ledgers")]
public string ValidatedLedgers { get; set; }
Property Value
Type Description
string

Extension Methods

Utilities.HasNextPage(BaseResponse)
  • Edit this page
  • View Source
In this article
Back to top Generated by DocFX