Package lv.odylab.evemanage.client.rpc.dto.blueprint

Examples of lv.odylab.evemanage.client.rpc.dto.blueprint.RequirementDto


            materialsTable.setWidget(i, 3, quantityLabel);
            materialToWidgetMap.put(material, quantityLabel);
        }

        for (int i = 0; i < manufacturingRequirements.size(); i++) {
            RequirementDto requirement = manufacturingRequirements.get(i);
            String imageUrl = imageUrlProvider.getImage16Url(requirement.getRequiredTypeCategoryID(), requirement.getRequiredTypeID(), requirement.getRequiredTypeNameGraphicIcon());
            Image image = new Image(imageUrl);
            image.setTitle(requirement.getRequiredTypeName());
            image.addStyleName(resources.css().image16());
            EveItemInfoLink imageItemInfoLink = new EveItemInfoLink(ccpJsMessages, image, requirement.getRequiredTypeID());

            materialsTable.setWidget(i + materials.size(), 0, imageItemInfoLink);
            materialsTable.setWidget(i + materials.size(), 1, new EveItemMarketDetailsLink(constants, urlMessages, ccpJsMessages, requirement.getRequiredTypeName(), requirement.getRequiredTypeID()));
            materialsTable.setWidget(i + materials.size(), 2, new Label("x"));
            QuantityLabel quantityLabel = new QuantityLabel();
            HorizontalPanel quantityAndDamagePerJobPanel = new HorizontalPanel();
            quantityAndDamagePerJobPanel.add(quantityLabel);
            BigDecimal damagePerJob = requirement.getDamagePerJob();
            if (BigDecimal.ONE.compareTo(damagePerJob) == 1 && BigDecimal.ZERO.compareTo(damagePerJob) != 0) {
                DamagePerJobLabel damagePerJobLabel = new DamagePerJobLabel(damagePerJob);
                damagePerJobLabel.addStyleName(resources.css().damagePerJob());
                quantityAndDamagePerJobPanel.add(damagePerJobLabel);
                quantityAndDamagePerJobPanel.setCellVerticalAlignment(damagePerJobLabel, HasVerticalAlignment.ALIGN_BOTTOM);
View Full Code Here


    private DisclosurePanel createDisclosurePanel(String headerText, List<RequirementDto> requirements, TimeLabel stationTimeLabel, TimeLabel posTimeLabel) {
        DisclosurePanel disclosurePanel = new DisclosurePanel(headerText);
        FlexTable disclosurePanelTable = new FlexTable();
        for (int i = 0; i < requirements.size(); i++) {
            RequirementDto requirement = requirements.get(i);
            String imageUrl = imageUrlProvider.getImage16Url(requirement.getRequiredTypeCategoryID(), requirement.getRequiredTypeID(), requirement.getRequiredTypeNameGraphicIcon());
            Image image = new Image(imageUrl);
            image.setTitle(requirement.getRequiredTypeName());
            image.addStyleName(resources.css().image16());
            EveItemInfoLink imageItemInfoLink = new EveItemInfoLink(ccpJsMessages, image, requirement.getRequiredTypeID());
            disclosurePanelTable.setWidget(i, 0, imageItemInfoLink);
            disclosurePanelTable.setWidget(i, 1, new EveItemMarketDetailsLink(constants, urlMessages, ccpJsMessages, requirement.getRequiredTypeName(), requirement.getRequiredTypeID()));
            disclosurePanelTable.setWidget(i, 2, new Label("x"));
            QuantityLabel quantityLabel = new QuantityLabel(requirement.getQuantity());
            HorizontalPanel quantityAndDamagePerJobPanel = new HorizontalPanel();
            quantityAndDamagePerJobPanel.add(quantityLabel);
            BigDecimal damagePerJob = requirement.getDamagePerJob();
            if (BigDecimal.ONE.compareTo(damagePerJob) == 1 && BigDecimal.ZERO.compareTo(damagePerJob) != 0) {
                DamagePerJobLabel damagePerJobLabel = new DamagePerJobLabel(damagePerJob);
                damagePerJobLabel.addStyleName(resources.css().damagePerJob());
                quantityAndDamagePerJobPanel.add(damagePerJobLabel);
                quantityAndDamagePerJobPanel.setCellVerticalAlignment(damagePerJobLabel, HasVerticalAlignment.ALIGN_BOTTOM);
View Full Code Here

            MaterialDto material = mapEntry.getKey();
            QuantityLabel quantityLabel = mapEntry.getValue();
            quantityLabel.setQuantity(calculator.calculateMaterialAmount(material.getQuantity(), blueprint.getMaterialLevel(), blueprintDetails.getWasteFactor()));
        }
        for (Map.Entry<RequirementDto, QuantityLabel> mapEntry : requirementToWidgetMap.entrySet()) {
            RequirementDto requirement = mapEntry.getKey();
            QuantityLabel quantityLabel = mapEntry.getValue();
            quantityLabel.setQuantity(requirement.getQuantity());
        }
        productionTimeStationText.setTime(calculator.calculateManufacturingTime(blueprintDetails.getProductionTime(), blueprintDetails.getProductivityModifier(), blueprint.getProductivityLevel(), 1.0));
        productionTimePosText.setTime(calculator.calculateManufacturingTime(blueprintDetails.getProductionTime(), blueprintDetails.getProductivityModifier(), blueprint.getProductivityLevel(), 0.75));
        researchProductivityTimeStationText.setTime(calculator.calculatePeResearchTime(blueprintDetails.getResearchProductivityTime(), 1.0));
        researchProductivityTimePosText.setTime(calculator.calculatePeResearchTime(blueprintDetails.getResearchProductivityTime(), 0.75));
View Full Code Here

        return materialDto;
    }

    @Override
    public RequirementDto map(RamTypeRequirementDto ramTypeRequirementDto, Class<RequirementDto> requirementDtoClass) {
        RequirementDto requirementDto = new RequirementDto();
        requirementDto.setActivityID(ramTypeRequirementDto.getActivityID());
        requirementDto.setActivityName(ramTypeRequirementDto.getActivityName());
        requirementDto.setRequiredTypeID(ramTypeRequirementDto.getRequiredTypeID());
        requirementDto.setRequiredTypeName(ramTypeRequirementDto.getRequiredTypeName());
        requirementDto.setRequiredTypeCategoryID(ramTypeRequirementDto.getRequiredTypeCategoryID());
        requirementDto.setRequiredTypeGroupID(ramTypeRequirementDto.getRequiredTypeGroupID());
        requirementDto.setRequiredTypeGroupName(ramTypeRequirementDto.getRequiredTypeGroupName());
        requirementDto.setQuantity(ramTypeRequirementDto.getQuantity());
        requirementDto.setDamagePerJob(new BigDecimal(ramTypeRequirementDto.getDamagePerJob()));
        requirementDto.setRequiredTypeNameGraphicIcon(ramTypeRequirementDto.getRequiredTypeIcon());
        return requirementDto;
    }
View Full Code Here

        return typeRequirementDto;
    }

    @Override
    public RequirementDto map(TypeRequirementDto typeRequirementDto, Class<RequirementDto> requirementDtoClass) {
        RequirementDto requirementDto = new RequirementDto();
        requirementDto.setActivityID(typeRequirementDto.getActivityID());
        requirementDto.setActivityName(typeRequirementDto.getActivityName());
        requirementDto.setRequiredTypeID(typeRequirementDto.getRequiredTypeID());
        requirementDto.setRequiredTypeName(typeRequirementDto.getRequiredTypeName());
        requirementDto.setRequiredTypeCategoryID(typeRequirementDto.getRequiredTypeCategoryID());
        requirementDto.setRequiredTypeGroupID(typeRequirementDto.getRequiredTypeGroupID());
        requirementDto.setRequiredTypeGroupName(typeRequirementDto.getRequiredTypeGroupName());
        requirementDto.setQuantity(typeRequirementDto.getQuantity());
        requirementDto.setDamagePerJob(new BigDecimal(typeRequirementDto.getDamagePerJob()));
        requirementDto.setRequiredTypeNameGraphicIcon(typeRequirementDto.getRequiredTypeNameGraphicIcon());
        return requirementDto;
    }
View Full Code Here

TOP

Related Classes of lv.odylab.evemanage.client.rpc.dto.blueprint.RequirementDto

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.