com.xeiam.xchange.bitstamp.dto.marketdata.BitstampOrderBook Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of xchange-bitstamp Show documentation
Show all versions of xchange-bitstamp Show documentation
XChange implementation for the Bitstamp Exchange
package com.xeiam.xchange.bitstamp.dto.marketdata;
import java.math.BigDecimal;
import java.util.List;
import com.fasterxml.jackson.annotation.JsonProperty;
/**
* @author Matija Mazi
*/
public class BitstampOrderBook {
private final Long timestamp;
private final List> bids;
private final List> asks;
/**
* Constructor
*
* @param timestamp
* @param bids
* @param asks
*/
public BitstampOrderBook(@JsonProperty("timestamp") Long timestamp, @JsonProperty("bids") List> bids,
@JsonProperty("asks") List> asks) {
this.bids = bids;
this.asks = asks;
this.timestamp = timestamp;
}
/**
* @return Timestamp in Unix milliseconds
*/
public Long getTimestamp() {
return timestamp;
}
/** (price, amount) */
public List> getBids() {
return bids;
}
/** (price, amount) */
public List> getAsks() {
return asks;
}
@Override
public String toString() {
return "BitstampOrderBook [timestamp=" + timestamp + ", bids=" + bids + ", asks=" + asks + "]";
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy