Class Trade


@Entity public class Trade extends BaseDomain
Trade (map "TRADES" table).
  • Constructor Details

    • Trade

      public Trade()
  • Method Details

    • equals

      public final boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public final int hashCode()
      Overrides:
      hashCode in class Object
    • getUid

      public Long getUid()
      Technical ID.
    • getTradeId

      public String getTradeId()
      An identifier set by the exchange that uniquely identifies the trade.
    • getType

      public OrderTypeDTO getType()
      Trade type i.e. bid (buy) or ask (sell).
    • getOrder

      public Order getOrder()
      The order responsible for this trade.
    • getCurrencyPair

      public String getCurrencyPair()
      Currency pair.
    • getAmount

      public CurrencyAmount getAmount()
      Amount that was ordered.
    • getPrice

      public CurrencyAmount getPrice()
      The price.
    • getFee

      public CurrencyAmount getFee()
      The fee that was charged by the exchange for this trade.
    • getUserReference

      public String getUserReference()
      An identifier provided by the user on placement that uniquely identifies the order of this trade.
    • getTimestamp

      public ZonedDateTime getTimestamp()
      The timestamp of the trade.
    • setUid

      public void setUid(Long uid)
      Technical ID.
    • setTradeId

      public void setTradeId(String tradeId)
      An identifier set by the exchange that uniquely identifies the trade.
    • setType

      public void setType(OrderTypeDTO type)
      Trade type i.e. bid (buy) or ask (sell).
    • setOrder

      public void setOrder(Order order)
      The order responsible for this trade.
    • setCurrencyPair

      public void setCurrencyPair(String currencyPair)
      Currency pair.
    • setAmount

      public void setAmount(CurrencyAmount amount)
      Amount that was ordered.
    • setPrice

      public void setPrice(CurrencyAmount price)
      The price.
    • setFee

      public void setFee(CurrencyAmount fee)
      The fee that was charged by the exchange for this trade.
    • setUserReference

      public void setUserReference(String userReference)
      An identifier provided by the user on placement that uniquely identifies the order of this trade.
    • setTimestamp

      public void setTimestamp(ZonedDateTime timestamp)
      The timestamp of the trade.
    • toString

      public String toString()
      Overrides:
      toString in class BaseDomain