Table of Contents

PairRateData<TSeries> Class

Definition

Namespace
Bodu.Financial.ExchangeRates
Assembly
Bodu.Financial.ExchangeRates.dll
Package
Bodu.Financial.ExchangeRates 1.0.0
Source
PairRateData{T}.cs

Represents the normalized result an IPairRateSource<TSeries> produces for one fetch: the resolved currency pair, its dated observations, and the source-specific series metadata.

public sealed record PairRateData<TSeries> : IEquatable<PairRateData<TSeries>>

Type Parameters

TSeries

The source-specific series-metadata type describing the fetched series.

Inheritance
PairRateData<TSeries>
Implements
Inherited Members
Extension Methods

Constructors

PairRateData(CurrencyPair, IReadOnlyList<RateObservation>, TSeries)

Represents the normalized result an IPairRateSource<TSeries> produces for one fetch: the resolved currency pair, its dated observations, and the source-specific series metadata.

public PairRateData(CurrencyPair Pair, IReadOnlyList<RateObservation> Observations, TSeries Series)

Parameters

Pair CurrencyPair

The resolved currency pair the observations quote.

Observations IReadOnlyList<RateObservation>

The dated observations for the pair, already restricted to the requested range. The consuming provider stamps each with its own provider identifier when materializing ExchangeRate values, so the source need not.

Series TSeries

The source-specific metadata describing the fetched series, surfaced for pair discovery.

Properties

Observations

The dated observations for the pair, already restricted to the requested range. The consuming provider stamps each with its own provider identifier when materializing ExchangeRate values, so the source need not.

public IReadOnlyList<RateObservation> Observations { get; init; }

Property Value

IReadOnlyList<RateObservation>

Pair

The resolved currency pair the observations quote.

public CurrencyPair Pair { get; init; }

Property Value

CurrencyPair

Series

The source-specific metadata describing the fetched series, surfaced for pair discovery.

public TSeries Series { get; init; }

Property Value

TSeries

Methods

Deconstruct(out CurrencyPair, out IReadOnlyList<RateObservation>, out TSeries)

public void Deconstruct(out CurrencyPair Pair, out IReadOnlyList<RateObservation> Observations, out TSeries Series)

Parameters

Pair CurrencyPair
Observations IReadOnlyList<RateObservation>
Series TSeries

Equals(PairRateData<TSeries>?)

Indicates whether the current object is equal to another object of the same type.

public bool Equals(PairRateData<TSeries>? other)

Parameters

other PairRateData<TSeries>

An object to compare with this object.

Returns

bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Determines whether the specified object is equal to the current object.

public override bool Equals(object? obj)

Parameters

obj object

The object to compare with the current object.

Returns

bool

true if the specified object is equal to the current object; otherwise, false.

GetHashCode()

Serves as the default hash function.

public override int GetHashCode()

Returns

int

A hash code for the current object.

ToString()

Returns a string that represents the current object.

public override string ToString()

Returns

string

A string that represents the current object.

Operators

operator ==(PairRateData<TSeries>?, PairRateData<TSeries>?)

public static bool operator ==(PairRateData<TSeries>? left, PairRateData<TSeries>? right)

Parameters

left PairRateData<TSeries>
right PairRateData<TSeries>

Returns

bool

operator !=(PairRateData<TSeries>?, PairRateData<TSeries>?)

public static bool operator !=(PairRateData<TSeries>? left, PairRateData<TSeries>? right)

Parameters

left PairRateData<TSeries>
right PairRateData<TSeries>

Returns

bool

Applies to

ProductVersions
.NET8, 10