API Support wrote:
Market depth can be received with ITick.getBidVolumes().
In order to receive 10 volumes instead of just 1 volume value strategy needs to subscribe to an instrument:
Set<Instrument> instruments = new HashSet<Instrument>();
instruments.add(Instrument.EURSEK);
context.setSubscribedInstruments(instruments, true);
Dear Support,
please read my question again: I need to get more than 10 items in market depth.
I tested this code you offered me
public void onTick(Instrument instrument, ITick tick) throws JFException {
if (instrument == Instrument.EURUSD) {
int count = tick.getBidVolumes().length;
console.getOut().println(count); // count is 10 every tick but I need more
}
}
and it give only 10 items limit. How to get more?