public class IndependentReserveTradeService extends IndependentReserveTradeServiceRaw implements PollingTradeService
exchange
Constructor and Description |
---|
IndependentReserveTradeService(Exchange exchange) |
Modifier and Type | Method and Description |
---|---|
boolean |
cancelOrder(String orderId)
cancels order with matching orderId
|
TradeHistoryParamPaging |
createTradeHistoryParams()
Create
TradeHistoryParams object specific to this exchange. |
OpenOrders |
getOpenOrders()
Assumes asking for the first 50 orders with the currency pair BTCUSD
|
UserTrades |
getTradeHistory(Object... arguments)
gets trade history for user's account
|
UserTrades |
getTradeHistory(TradeHistoryParams params)
Optional parameters:
TradeHistoryParamPaging.getPageNumber() indexed from 0 |
String |
placeLimitOrder(LimitOrder limitOrder)
Place a limit order
|
String |
placeMarketOrder(MarketOrder marketOrder)
Place a market order
|
getIndependentReserveOpenOrders, getIndependentReserveTradeHistory, independentReserveCancelOrder, independentReservePlaceLimitOrder
getExchangeSymbols, verifyOrder, verifyOrder, verifyOrder
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
verifyOrder, verifyOrder
getExchangeSymbols
public IndependentReserveTradeService(Exchange exchange)
public OpenOrders getOpenOrders() throws ExchangeException, NotAvailableFromExchangeException, NotYetImplementedForExchangeException, IOException
getOpenOrders
in interface PollingTradeService
ExchangeException
- - Indication that the exchange reported some kind of error with the request or responseNotAvailableFromExchangeException
- - Indication that the exchange does not support the requested function or dataNotYetImplementedForExchangeException
- - Indication that the exchange supports the requested function or data, but it has not yet been
implementedIOException
- - Indication that a networking error occurred while fetching JSON datapublic String placeMarketOrder(MarketOrder marketOrder) throws ExchangeException, NotAvailableFromExchangeException, NotYetImplementedForExchangeException, IOException
PollingTradeService
placeMarketOrder
in interface PollingTradeService
ExchangeException
- - Indication that the exchange reported some kind of error with the request or responseNotAvailableFromExchangeException
- - Indication that the exchange does not support the requested function or dataNotYetImplementedForExchangeException
- - Indication that the exchange supports the requested function or data, but it has not yet been
implementedIOException
- - Indication that a networking error occurred while fetching JSON datapublic String placeLimitOrder(LimitOrder limitOrder) throws ExchangeException, NotAvailableFromExchangeException, NotYetImplementedForExchangeException, IOException
PollingTradeService
placeLimitOrder
in interface PollingTradeService
ExchangeException
- - Indication that the exchange reported some kind of error with the request or responseNotAvailableFromExchangeException
- - Indication that the exchange does not support the requested function or dataNotYetImplementedForExchangeException
- - Indication that the exchange supports the requested function or data, but it has not yet been
implementedIOException
- - Indication that a networking error occurred while fetching JSON datapublic boolean cancelOrder(String orderId) throws ExchangeException, NotAvailableFromExchangeException, NotYetImplementedForExchangeException, IOException
PollingTradeService
cancelOrder
in interface PollingTradeService
ExchangeException
- - Indication that the exchange reported some kind of error with the request or responseNotAvailableFromExchangeException
- - Indication that the exchange does not support the requested function or dataNotYetImplementedForExchangeException
- - Indication that the exchange supports the requested function or data, but it has not yet been
implementedIOException
- - Indication that a networking error occurred while fetching JSON datapublic UserTrades getTradeHistory(Object... arguments) throws ExchangeException, NotAvailableFromExchangeException, NotYetImplementedForExchangeException, IOException
PollingTradeService
getTradeHistory
in interface PollingTradeService
ExchangeException
- - Indication that the exchange reported some kind of error with the request or responseNotAvailableFromExchangeException
- - Indication that the exchange does not support the requested function or dataNotYetImplementedForExchangeException
- - Indication that the exchange supports the requested function or data, but it has not yet been
implementedIOException
- - Indication that a networking error occurred while fetching JSON datapublic UserTrades getTradeHistory(TradeHistoryParams params) throws IOException
TradeHistoryParamPaging.getPageNumber()
indexed from 0getTradeHistory
in interface PollingTradeService
params
- The parameters describing the filter. Note that TradeHistoryParams
is an empty interface. Exact set of interfaces that are
required or supported by this method is described by the type of object returned from PollingTradeService.createTradeHistoryParams()
and the javadoc
of the method.IOException
- - Indication that a networking error occurred while fetching JSON dataPollingTradeService.getTradeHistory(Object...)
,
PollingTradeService.createTradeHistoryParams()
,
TradeHistoryParamsAll
public TradeHistoryParamPaging createTradeHistoryParams()
PollingTradeService
TradeHistoryParams
object specific to this exchange. Object created by this method may be used to discover supported and required
PollingTradeService.getTradeHistory(TradeHistoryParams)
parameters and should be passed only to the method in the same class as the createTradeHistoryParams
that created the object.createTradeHistoryParams
in interface PollingTradeService
Copyright © 2012–2018 Xeiam, LLC. All rights reserved.