-
Notifications
You must be signed in to change notification settings - Fork 86
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
20 changed files
with
766 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
# Changelog | ||
## 1.1.0 | ||
CHAIN UPGRADE | ||
* [\#88](https://github.com/binance-chain/java-sdk/pull/88) [RPC] [API] enable side chain governance transaction | ||
* [\#89](https://github.com/binance-chain/java-sdk/pull/89) [RPC] [API] enable side chain unbind transaction, and modify the structure of claimMsg | ||
|
||
## 1.0.7 | ||
CHAIN UPGRADE | ||
* [\#86](https://github.com/binance-chain/java-sdk/pull/86) [RPC] [API] Add Pending match flag to Depth API response | ||
* [\#80](https://github.com/binance-chain/java-sdk/pull/80) [RPC] [API] Support Mini Token |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
109 changes: 109 additions & 0 deletions
109
src/main/java/com/binance/dex/api/client/domain/MiniToken.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
package com.binance.dex.api.client.domain; | ||
|
||
import com.binance.dex.api.client.BinanceDexConstants; | ||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties; | ||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import org.apache.commons.lang3.builder.ToStringBuilder; | ||
|
||
@JsonIgnoreProperties(ignoreUnknown = true) | ||
public class MiniToken { | ||
private String name; | ||
private String symbol; | ||
@JsonProperty("original_symbol") | ||
private String originalSymbol; | ||
@JsonProperty("total_supply") | ||
private Long totalSupply; | ||
@JsonProperty("token_type") | ||
private Integer tokenType; | ||
@JsonProperty("token_uri") | ||
private String tokenURI; | ||
private String owner; | ||
private boolean mintable; | ||
|
||
public String getName() { | ||
return name; | ||
} | ||
|
||
public void setName(String name) { | ||
this.name = name; | ||
} | ||
|
||
public String getSymbol() { | ||
return symbol; | ||
} | ||
|
||
public void setSymbol(String symbol) { | ||
this.symbol = symbol; | ||
} | ||
|
||
public String getOriginalSymbol() { | ||
return originalSymbol; | ||
} | ||
|
||
public void setOriginalSymbol(String originalSymbol) { | ||
this.originalSymbol = originalSymbol; | ||
} | ||
|
||
public Long getTotalSupply() { | ||
return totalSupply; | ||
} | ||
|
||
public void setTotalSupply(Long totalSupply) { | ||
this.totalSupply = totalSupply; | ||
} | ||
|
||
public Integer getTokenType() { | ||
return tokenType; | ||
} | ||
|
||
public void setTokenType(Integer tokenType) { | ||
this.tokenType = tokenType; | ||
} | ||
|
||
public String getTokenURI() { | ||
return tokenURI; | ||
} | ||
|
||
public void setTokenURI(String tokenURI) { | ||
this.tokenURI = tokenURI; | ||
} | ||
|
||
public String getOwner() { | ||
return owner; | ||
} | ||
|
||
public void setOwner(String owner) { | ||
this.owner = owner; | ||
} | ||
|
||
public boolean isMintable() { | ||
return mintable; | ||
} | ||
|
||
public void setMintable(boolean mintable) { | ||
this.mintable = mintable; | ||
} | ||
|
||
public void setTotalSupply(String totalSupply){ | ||
if (totalSupply != null) { | ||
if (totalSupply.indexOf('.') > 0) { | ||
totalSupply = totalSupply.substring(0, totalSupply.indexOf('.')); | ||
this.totalSupply = Long.parseLong(totalSupply) * 100000000L; | ||
} | ||
} | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return new ToStringBuilder(this, BinanceDexConstants.BINANCE_DEX_TO_STRING_STYLE) | ||
.append("name", name) | ||
.append("symbol", symbol) | ||
.append("originalSymbol", originalSymbol) | ||
.append("totalSupply", totalSupply) | ||
.append("tokenType", tokenType) | ||
.append("tokenURI", tokenURI) | ||
.append("owner", owner) | ||
.append("mintable", mintable) | ||
.toString(); | ||
} | ||
} |
Oops, something went wrong.