Options
All
  • Public
  • Public/Protected
  • All
Menu

Hierarchy

  • OrderbookRepository

Index

Constructors

constructor

Properties

Private models

models: Models

Methods

addCurrencies

  • addCurrencies(currencies: db.CurrencyCreationAttributes[]): Promise<CurrencyInstance[]>

addCurrency

  • addCurrency(currency: db.CurrencyCreationAttributes): Promise<CurrencyInstance>

addOrderIfNotExists

  • addOrderIfNotExists(order: db.OrderCreationAttributes): Promise<undefined | OrderInstance>
  • Adds an order to the database if it doesn't already exist.

    Parameters

    • order: db.OrderCreationAttributes

      order to persist

    Returns Promise<undefined | OrderInstance>

    the created order instance, or undefined if it already existed

addPair

  • addPair(pair: db.PairCreationAttributes): Promise<PairInstance>

addPairs

  • addPairs(pairs: db.PairCreationAttributes[]): Promise<PairInstance[]>

addTrade

  • addTrade(trade: db.TradeCreationAttributes): Promise<TradeInstance>

getCurrencies

getOrder

getPairs

getTrades

  • getTrades(limit?: undefined | number): Promise<TradeInstance[]>

Generated using TypeDoc