Swap DTO
This commit is contained in:
7
src/main/java/stream/dto/Exchange.java
Normal file
7
src/main/java/stream/dto/Exchange.java
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
package stream.dto;
|
||||||
|
|
||||||
|
enum Exchange {
|
||||||
|
UNISWAP_V2,
|
||||||
|
UNISWAP_V3,
|
||||||
|
UNISWAP_V4,
|
||||||
|
}
|
||||||
18
src/main/java/stream/dto/Swap.java
Normal file
18
src/main/java/stream/dto/Swap.java
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
package stream.dto;
|
||||||
|
|
||||||
|
import java.io.Serial;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
|
||||||
|
public class Swap extends ChainId {
|
||||||
|
@Serial
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
Long time; // milliseconds
|
||||||
|
Exchange exchange;
|
||||||
|
String pool; // address
|
||||||
|
String takerAsset; // token address
|
||||||
|
String makerAsset; // token address
|
||||||
|
BigDecimal amount; // positive means the taker bought; negative means the taker sold.
|
||||||
|
BigDecimal price;
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user