| | |
| | | import com.yami.trading.bean.data.domain.Realtime; |
| | | import com.yami.trading.bean.data.domain.Trade; |
| | | import com.yami.trading.bean.item.domain.Item; |
| | | import com.yami.trading.common.exception.YamiShopBindException; |
| | | import com.yami.trading.common.util.Arith; |
| | | import com.yami.trading.huobi.data.AdjustmentValueCache; |
| | | import com.yami.trading.huobi.data.DataCache; |
| | |
| | | Item item = itemService.findBySymbol(symbol); |
| | | symbol = item.getSymbol(); |
| | | item = this.itemService.findBySymbol(symbol); |
| | | //停牌时不更新 |
| | | if (itemService.isSuspended(symbol)) { |
| | | return; |
| | | } |
| | | Double currentValue = AdjustmentValueCache.getCurrentValue().get(symbol).doubleValue(); |
| | | double close = event.getTicker().getClose().doubleValue(); |
| | | double vol = event.getTicker().getVol().doubleValue(); |
| | |
| | | realtime.setLow(new BigDecimal(low)); |
| | | } |
| | | |
| | | Double h24Before = DataCache.getRealtime24HBeforeOpen().get(symbol); |
| | | /*ouble h24Before = DataCache.getRealtime24HBeforeOpen().get(symbol); |
| | | if (h24Before != null) { |
| | | realtime.setOpen(new BigDecimal(h24Before)); |
| | | } |
| | | }*/ |
| | | |
| | | /*if (realtime.getSymbol().equals("axsusdt")) { |
| | | System.out.println("axsusdt2" + realtime); |
| | | }*/ |
| | | DataCache.putRealtime(symbol, realtime); |
| | | // System.out.println(JSONObject.toJSONString(realtime)); |
| | | } |