public class ComputablePrice extends Object
| Type | Property and Description |
|---|---|
javafx.beans.property.ReadOnlyIntegerProperty |
marketSaturation |
javafx.beans.property.ReadOnlyIntegerProperty |
maxValueBuy |
javafx.beans.property.ReadOnlyIntegerProperty |
maxValueSell |
| Modifier and Type | Field and Description |
|---|---|
private IPriceCalculation |
calculation |
private javafx.beans.property.ReadOnlyIntegerProperty |
maxValueBuy |
private javafx.beans.property.ReadOnlyIntegerProperty |
maxValueSell |
private javafx.beans.property.ReadOnlyIntegerProperty |
minValueBuy |
private javafx.beans.property.ReadOnlyIntegerProperty |
minValueSell |
private String |
name |
private javafx.beans.property.ReadOnlyIntegerProperty |
saturation |
| Constructor and Description |
|---|
ComputablePrice(int maxValueBuy,
int minValueBuy,
int maxValueSell,
int minValueSell,
int saturation,
String name) |
| Modifier and Type | Method and Description |
|---|---|
int |
buyPrice(javafx.beans.property.IntegerProperty availableAmount,
javafx.beans.binding.IntegerBinding amountToBuy)
Integer binding for the buy price.
|
int |
computeBuyPrice(int availableAmount,
int amountToBuy)
Deprecated.
|
int |
computeSellPrice(int availableAmount,
int amountToSell)
Deprecated.
|
int |
getMarketSaturation()
Gets the value of the property marketSaturation.
|
int |
getMaxValueBuy()
Gets the value of the property maxValueBuy.
|
int |
getMaxValueSell()
Retrieve the highest price of this ware when only on item is available
|
int |
getMinValueBuy() |
int |
getMinValueSell()
Retrieve the lowest price this ware is soled (at market saturation)
|
(package private) int |
internalBuyPriceCalculation(int availableAmount,
int amountToBuy)
Internal method to calculate the buy price.
|
(package private) int |
internalSellPriceCalculation(int availableAmount,
int amountToSell)
Internal calculation of the sell price.
|
javafx.beans.property.ReadOnlyIntegerProperty |
marketSaturationProperty() |
javafx.beans.property.ReadOnlyIntegerProperty |
maxValueBuyProperty() |
javafx.beans.property.ReadOnlyIntegerProperty |
maxValueSellProperty() |
javafx.beans.property.ReadOnlyIntegerProperty |
minValueBuy() |
javafx.beans.property.ReadOnlyIntegerProperty |
minValueSell() |
int |
sellPrice(javafx.beans.property.IntegerProperty availableAmount,
javafx.beans.binding.IntegerBinding amountToSell) |
private final IPriceCalculation calculation
private final javafx.beans.property.ReadOnlyIntegerProperty maxValueBuy
private final javafx.beans.property.ReadOnlyIntegerProperty minValueBuy
private final javafx.beans.property.ReadOnlyIntegerProperty maxValueSell
private final javafx.beans.property.ReadOnlyIntegerProperty minValueSell
private final javafx.beans.property.ReadOnlyIntegerProperty saturation
private final String name
public ComputablePrice(int maxValueBuy,
int minValueBuy,
int maxValueSell,
int minValueSell,
int saturation,
String name)
public int getMaxValueBuy()
public javafx.beans.property.ReadOnlyIntegerProperty maxValueBuyProperty()
public int getMaxValueSell()
public javafx.beans.property.ReadOnlyIntegerProperty maxValueSellProperty()
public int getMinValueSell()
public javafx.beans.property.ReadOnlyIntegerProperty minValueSell()
public int getMinValueBuy()
public javafx.beans.property.ReadOnlyIntegerProperty minValueBuy()
public int getMarketSaturation()
public javafx.beans.property.ReadOnlyIntegerProperty marketSaturationProperty()
@Deprecated public int computeSellPrice(int availableAmount, int amountToSell)
int internalSellPriceCalculation(int availableAmount,
int amountToSell)
availableAmount - amountToSell - @Deprecated public int computeBuyPrice(int availableAmount, int amountToBuy)
int internalBuyPriceCalculation(int availableAmount,
int amountToBuy)
availableAmount - amountToBuy - public int buyPrice(javafx.beans.property.IntegerProperty availableAmount,
javafx.beans.binding.IntegerBinding amountToBuy)
availableAmount - amountToBuy - public int sellPrice(javafx.beans.property.IntegerProperty availableAmount,
javafx.beans.binding.IntegerBinding amountToSell)
Copyright © 2011-2015 Sahits GmbH. All Rights Reserved.