Skip to content

Commit 259bb01

Browse files
committed
fix: remove deposit fee methods
1 parent 5328e78 commit 259bb01

File tree

3 files changed

+51
-51
lines changed

3 files changed

+51
-51
lines changed

src/main/java/com/cryptomarket/sdk/rest/CryptomarketRestClient.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1388,7 +1388,6 @@ public String getEstimateWithdrawalFee(String currency, String amount, @Nullable
13881388
*/
13891389
public List<Fee> getEstimateWithdrawalFees(List<FeeRequest> feeRequests) throws CryptomarketSDKException;
13901390

1391-
13921391
/**
13931392
* Get estimates of withdrawal fees
13941393
* <p>
@@ -1402,7 +1401,6 @@ public String getEstimateWithdrawalFee(String currency, String amount, @Nullable
14021401
*/
14031402
public List<Fee> getBulkEstimateWithdrawalFees(List<FeeRequest> feeRequests) throws CryptomarketSDKException;
14041403

1405-
14061404
/**
14071405
* Get an estimate of the deposit fee
14081406
* <p>
@@ -1416,15 +1414,16 @@ public String getEstimateWithdrawalFee(String currency, String amount, @Nullable
14161414
* @return The expected fee
14171415
* @throws CryptomarketSDKException
14181416
*/
1419-
public String getEstimateDepositFee(String currency, String amount, @Nullable String networkCode)
1420-
throws CryptomarketSDKException;
1417+
// public String getEstimateDepositFee(String currency, String amount, @Nullable
1418+
// String networkCode) throws CryptomarketSDKException;
14211419

14221420
/**
14231421
* @see #getEstimateWithdrawalFee(String, String, String)
14241422
* @param paramsBuilder
14251423
* @throws CryptomarketSDKException
14261424
*/
1427-
public String getEstimateDepositFee(ParamsBuilder paramsBuilder) throws CryptomarketSDKException;
1425+
// public String getEstimateDepositFee(ParamsBuilder paramsBuilder) throws
1426+
// CryptomarketSDKException;
14281427

14291428
/**
14301429
* Get estimates of deposit fees
@@ -1437,7 +1436,8 @@ public String getEstimateDepositFee(String currency, String amount, @Nullable St
14371436
* @return the list of fees
14381437
* @throws CryptomarketSDKException
14391438
*/
1440-
public List<Fee> getBulkEstimateDepositFees(List<FeeRequest> feeRequests) throws CryptomarketSDKException;
1439+
// public List<Fee> getBulkEstimateDepositFees(List<FeeRequest> feeRequests)
1440+
// throws CryptomarketSDKException;
14411441

14421442
/**
14431443
* Converts between currencies

src/main/java/com/cryptomarket/sdk/rest/CryptomarketRestClientImpl.java

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -922,34 +922,34 @@ public List<Fee> getBulkEstimateWithdrawalFees(List<FeeRequest> feeRequests) thr
922922
return adapter.listFromJson(jsonResponse, Fee.class);
923923
}
924924

925-
@Override
926-
public String getEstimateDepositFee(String currency, String amount, String networkCode)
927-
throws CryptomarketSDKException {
928-
return getEstimateDepositFee(new ParamsBuilder()
929-
.currency(currency)
930-
.networkCode(networkCode)
931-
.amount(amount));
932-
}
933-
934-
@Override
935-
public String getEstimateDepositFee(ParamsBuilder paramsBuilder) throws CryptomarketSDKException {
936-
paramsBuilder.checkRequired(Arrays.asList(
937-
ArgNames.CURRENCY,
938-
ArgNames.AMOUNT));
939-
String jsonResponse = httpClient.get(
940-
"wallet/crypto/fee/deposit/estimate",
941-
paramsBuilder.build());
942-
return adapter.objectFromJsonValue(jsonResponse, "fee", String.class);
943-
}
944-
945-
@Override
946-
public List<Fee> getBulkEstimateDepositFees(List<FeeRequest> feeRequests) throws CryptomarketSDKException {
947-
var payload = adapter.listToJson(feeRequests, FeeRequest.class);
948-
String jsonResponse = httpClient.post(
949-
"wallet/crypto/fee/deposit/estimate/bulk",
950-
payload);
951-
return adapter.listFromJson(jsonResponse, Fee.class);
952-
}
925+
// @Override
926+
// public String getEstimateDepositFee(String currency, String amount, String networkCode)
927+
// throws CryptomarketSDKException {
928+
// return getEstimateDepositFee(new ParamsBuilder()
929+
// .currency(currency)
930+
// .networkCode(networkCode)
931+
// .amount(amount));
932+
// }
933+
934+
// @Override
935+
// public String getEstimateDepositFee(ParamsBuilder paramsBuilder) throws CryptomarketSDKException {
936+
// paramsBuilder.checkRequired(Arrays.asList(
937+
// ArgNames.CURRENCY,
938+
// ArgNames.AMOUNT));
939+
// String jsonResponse = httpClient.get(
940+
// "wallet/crypto/fee/deposit/estimate",
941+
// paramsBuilder.build());
942+
// return adapter.objectFromJsonValue(jsonResponse, "fee", String.class);
943+
// }
944+
945+
// @Override
946+
// public List<Fee> getBulkEstimateDepositFees(List<FeeRequest> feeRequests) throws CryptomarketSDKException {
947+
// var payload = adapter.listToJson(feeRequests, FeeRequest.class);
948+
// String jsonResponse = httpClient.post(
949+
// "wallet/crypto/fee/deposit/estimate/bulk",
950+
// payload);
951+
// return adapter.listFromJson(jsonResponse, Fee.class);
952+
// }
953953

954954
@Override
955955
public List<String> convertBetweenCurrencies(

src/test/java/com/cryptomarket/sdk/TestRestClientWalletManagement.java

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -143,23 +143,23 @@ public void testGetEstimateWithdrawFee() throws CryptomarketSDKException {
143143
}
144144
}
145145

146-
@Test
147-
public void testGetEstimateDepositFees() throws CryptomarketSDKException {
148-
var fees = client
149-
.getBulkEstimateDepositFees(List.of(new FeeRequest("EOS", "100"), new FeeRequest("ETH", "100")));
150-
if (fees.size() != 2) {
151-
fail("invalid amount of fees");
152-
}
153-
fees.forEach(Checker.checkFee);
154-
}
155-
156-
@Test
157-
public void testGetEstimateDepositFee() throws CryptomarketSDKException {
158-
String estimate = client.getEstimateDepositFee("EOS", "100", null);
159-
if (estimate.equals("")) {
160-
fail();
161-
}
162-
}
146+
// @Test
147+
// public void testGetEstimateDepositFees() throws CryptomarketSDKException {
148+
// var fees = client
149+
// .getBulkEstimateDepositFees(List.of(new FeeRequest("EOS", "100"), new FeeRequest("ETH", "100")));
150+
// if (fees.size() != 2) {
151+
// fail("invalid amount of fees");
152+
// }
153+
// fees.forEach(Checker.checkFee);
154+
// }
155+
156+
// @Test
157+
// public void testGetEstimateDepositFee() throws CryptomarketSDKException {
158+
// String estimate = client.getEstimateDepositFee("EOS", "100", null);
159+
// if (estimate.equals("")) {
160+
// fail();
161+
// }
162+
// }
163163

164164
@Test
165165
public void testCryptoAddressBelongsToCurrentAccount() throws CryptomarketSDKException {

0 commit comments

Comments
 (0)