/** * Creates a new {@link EmrClusterPriceDto} object from the given parameters. * * @param availabilityZone the AZ * @param masterPrice the master instance's price * @param corePrice the core instance's price * @param taskPrice the task instance's price * * @return the new {@link EmrClusterPriceDto} */ private EmrClusterPriceDto createEmrClusterPrice(AvailabilityZone availabilityZone, Ec2PriceDto masterPrice, Ec2PriceDto corePrice, Ec2PriceDto taskPrice) { EmrClusterPriceDto emrClusterPrice = new EmrClusterPriceDto(); emrClusterPrice.setAvailabilityZone(availabilityZone.getZoneName()); emrClusterPrice.setMasterPrice(masterPrice); emrClusterPrice.setCorePrice(corePrice); emrClusterPrice.setTaskPrice(taskPrice); return emrClusterPrice; }
/** * Creates a new {@link EmrClusterPriceDto} object from the given parameters. * * @param availabilityZone the AZ * @param masterPrice the master instance's price * @param corePrice the core instance's price * @param taskPrice the task instance's price * * @return the new {@link EmrClusterPriceDto} */ private EmrClusterPriceDto createEmrClusterPrice(AvailabilityZone availabilityZone, Ec2PriceDto masterPrice, Ec2PriceDto corePrice, Ec2PriceDto taskPrice) { EmrClusterPriceDto emrClusterPrice = new EmrClusterPriceDto(); emrClusterPrice.setAvailabilityZone(availabilityZone.getZoneName()); emrClusterPrice.setMasterPrice(masterPrice); emrClusterPrice.setCorePrice(corePrice); emrClusterPrice.setTaskPrice(taskPrice); return emrClusterPrice; }
private EmrClusterPriceDto createSimpleEmrClusterPrice(final String availabilityZone, final BigDecimal instancePrice) { EmrClusterPriceDto emrClusterPriceDto = new EmrClusterPriceDto(); emrClusterPriceDto.setAvailabilityZone(availabilityZone); if (instancePrice != null) { Ec2PriceDto corePrice = new Ec2PriceDto(); corePrice.setInstanceCount(1); corePrice.setInstancePrice(instancePrice); emrClusterPriceDto.setCorePrice(corePrice); } return emrClusterPriceDto; }
sourceCorePrice = this.getCorePrice(); Ec2PriceDto copyCorePrice = ((Ec2PriceDto) strategy.copy(LocatorUtils.property(locator, "corePrice", sourceCorePrice), sourceCorePrice, (this.corePrice!= null))); copy.setCorePrice(copyCorePrice); } else { if (corePriceShouldBeCopiedAndSet == Boolean.FALSE) {