Table of Contents

Interface IOrderBookUpdater<TBook, S, D>

Namespace
Virtufin.Core.Position
Assembly
Virtufin.Core.dll

Applies venue snapshot/diff data to a maintained TBook. S is the snapshot data type and D the diff data type.

public interface IOrderBookUpdater<TBook, S, D> where TBook : IOrderBook

Type Parameters

TBook

Maintained book type.

S

Snapshot data type.

D

Diff data type.

Remarks

The updater is stateless: all live state (levels, update id, lifecycle) lives on the book, so one updater instance can serve many books.

Methods

ApplyDiff(TBook, D)

Apply one diff to book.

OrderBookUpdateStatus ApplyDiff(TBook book, D diff)

Parameters

book TBook

Book to mutate.

diff D

Diff data.

Returns

OrderBookUpdateStatus

The outcome of the application.

ApplySnapshot(TBook, S)

Bootstrap (or re-bootstrap) book from a snapshot.

void ApplySnapshot(TBook book, S snapshot)

Parameters

book TBook

Book to populate.

snapshot S

Snapshot data.