Package lv.odylab.evemanage.integration.evemetricsapi.dto

Examples of lv.odylab.evemanage.integration.evemetricsapi.dto.ItemPriceDto


        Map<Long, ItemPriceDto> typeIdToPriceMap = new HashMap<Long, ItemPriceDto>();
        for (ItemPriceDto itemPriceDto : itemPriceDtos) {
            typeIdToPriceMap.put(itemPriceDto.getTypeID(), itemPriceDto);
        }
        for (PriceSetItem priceSetItem : priceSetItems) {
            ItemPriceDto itemPriceDto = typeIdToPriceMap.get(priceSetItem.getItemTypeID());
            priceSetItem.setPrice(String.valueOf(itemPriceDto.getMedian()));
        }
        return priceSetItems;
    }
View Full Code Here


        return marketStatDto;
    }

    @Override
    public ItemPriceDto map(ItemPriceType itemPriceType, Class<ItemPriceDto> itemPriceDtoClass) {
        ItemPriceDto itemPriceDto = new ItemPriceDto();
        itemPriceDto.setTypeID(itemPriceType.getId());
        BigDecimal medianBuy = itemPriceType.getRegionsTypeData().get(0).getBuyPrices().getMedian();
        BigDecimal medianSell = itemPriceType.getRegionsTypeData().get(0).getSellPrices().getMedian();
        BigDecimal medianBuySell = medianBuy.add(medianSell).divide(new BigDecimal(2)).setScale(2, RoundingMode.HALF_UP);
        itemPriceDto.setMedian(medianBuySell);
        return itemPriceDto;
    }
View Full Code Here

TOP

Related Classes of lv.odylab.evemanage.integration.evemetricsapi.dto.ItemPriceDto

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.