Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Working version of BTCE withdrawal support. Not tested.
- Loading branch information
Showing
6 changed files
with
111 additions
and
33 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
22 changes: 22 additions & 0 deletions
22
xchange-btce/src/main/java/com/xeiam/xchange/btce/v3/dto/account/BTCEWithDrawInfoReturn.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,22 @@ | ||
package com.xeiam.xchange.btce.v3.dto.account; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
import com.xeiam.xchange.btce.v3.dto.BTCEReturn; | ||
|
||
/** | ||
* @author Ondřej Novotný | ||
*/ | ||
public class BTCEWithDrawInfoReturn extends BTCEReturn<BTCEWithdrawInfo> { | ||
|
||
/** | ||
* Constructor | ||
* | ||
* @param success True if successful | ||
* @param value The BTC-e account info | ||
* @param error Any error | ||
*/ | ||
public BTCEWithDrawInfoReturn(@JsonProperty("success") boolean success, @JsonProperty("return") BTCEWithdrawInfo value, | ||
@JsonProperty("error") String error) { | ||
super(success, value, error); | ||
} | ||
} |
54 changes: 54 additions & 0 deletions
54
xchange-btce/src/main/java/com/xeiam/xchange/btce/v3/dto/account/BTCEWithdrawInfo.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,54 @@ | ||
package com.xeiam.xchange.btce.v3.dto.account; | ||
|
||
import java.math.BigDecimal; | ||
import java.text.MessageFormat; | ||
import java.util.Map; | ||
|
||
import com.fasterxml.jackson.annotation.JsonProperty; | ||
|
||
/** | ||
* @author Ondřej Novotný | ||
*/ | ||
public class BTCEWithdrawInfo { | ||
|
||
private final Map<String, BigDecimal> funds; | ||
private final int tId; | ||
|
||
|
||
private final int amountSent; | ||
|
||
/** | ||
* Constructor | ||
* | ||
* @param tId | ||
* @param amountSent | ||
* @param funds The funds | ||
*/ | ||
public BTCEWithdrawInfo(@JsonProperty("tId") int tId, @JsonProperty("amountSent") BigDecimal amountSent, | ||
@JsonProperty("funds") Map<String, BigDecimal> funds) { | ||
this.funds = funds; | ||
this.tId = tId; | ||
this.amountSent = tId; | ||
} | ||
|
||
public int gettId() { | ||
return tId; | ||
} | ||
|
||
public int getAmountSent() { | ||
return amountSent; | ||
} | ||
|
||
public Map<String, BigDecimal> getFunds() { | ||
|
||
return funds; | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
|
||
return MessageFormat.format("BTCEAccountInfo[tId={0}, amountSent={1}, funds=''{2}''']", tId, | ||
amountSent, funds); | ||
} | ||
|
||
} |
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