nxt.ae

## Class TradeHome

- java.lang.Object
- - nxt.ae.TradeHome

-     public final class TradeHome
      extends java.lang.Object

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `static class` | `TradeHome.Event`
    `class` | `TradeHome.Trade`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static boolean` | `addListener(Listener<TradeHome.Trade> listener, TradeHome.Event eventType)`
    `static TradeHome` | `forChain(ChildChain childChain)`
    `DbIterator<TradeHome.Trade>` | `getAccountAssetTrades(long accountId, long assetId, int from, int to)`
    `DbIterator<TradeHome.Trade>` | `getAccountTrades(long accountId, int from, int to)`
    `DbIterator<TradeHome.Trade>` | `getAllTrades(int from, int to)`
    `DbIterator<TradeHome.Trade>` | `getAskOrderTrades(byte[] askOrderHash, int from, int to)`
    `DbIterator<TradeHome.Trade>` | `getAssetTrades(long assetId, int from, int to)`
    `DbIterator<TradeHome.Trade>` | `getBidOrderTrades(byte[] bidOrderHash, int from, int to)`
    `int` | `getCount()`
    `java.util.List<TradeHome.Trade>` | `getLastTrades(long[] assetIds)`
    `TradeHome.Trade` | `getTrade(byte[] askOrderHash, byte[] bidOrderHash)`
    `int` | `getTradeCount(long assetId)`
    `static boolean` | `removeListener(Listener<TradeHome.Trade> listener, TradeHome.Event eventType)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Method Detail

    - #### forChain

          public static TradeHome forChain(ChildChain childChain)

    - #### addListener

          public static boolean addListener(Listener<TradeHome.Trade> listener,
                                            TradeHome.Event eventType)

    - #### removeListener

          public static boolean removeListener(Listener<TradeHome.Trade> listener,
                                               TradeHome.Event eventType)

    - #### getAllTrades

          public DbIterator<TradeHome.Trade> getAllTrades(int from,
                                                          int to)

    - #### getCount

          public int getCount()

    - #### getTrade

          public TradeHome.Trade getTrade(byte[] askOrderHash,
                                          byte[] bidOrderHash)

    - #### getAssetTrades

          public DbIterator<TradeHome.Trade> getAssetTrades(long assetId,
                                                            int from,
                                                            int to)

    - #### getLastTrades

          public java.util.List<TradeHome.Trade> getLastTrades(long[] assetIds)

    - #### getAccountTrades

          public DbIterator<TradeHome.Trade> getAccountTrades(long accountId,
                                                              int from,
                                                              int to)

    - #### getAccountAssetTrades

          public DbIterator<TradeHome.Trade> getAccountAssetTrades(long accountId,
                                                                   long assetId,
                                                                   int from,
                                                                   int to)

    - #### getAskOrderTrades

          public DbIterator<TradeHome.Trade> getAskOrderTrades(byte[] askOrderHash,
                                                               int from,
                                                               int to)

    - #### getBidOrderTrades

          public DbIterator<TradeHome.Trade> getBidOrderTrades(byte[] bidOrderHash,
                                                               int from,
                                                               int to)

    - #### getTradeCount

          public int getTradeCount(long assetId)