public class PriceRangeCalculationHelper
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
MAX_NEGATIVE_PRICES_STEPS_MULTIPLIER_POWER |
static int |
MAX_POSITIVE_PRICES_STEPS_MULTIPLIER_POWER |
static int[] |
PRICES_STEPS_MULTIPLIERS |
| Constructor and Description |
|---|
PriceRangeCalculationHelper() |
| Modifier and Type | Method and Description |
|---|---|
static Layer1PriceAxisRangeCalculatable.ResultPriceAxisInfo |
getGoodNumbersCalculation(double minValue,
double maxValue,
double linesCount)
Provides an implementation of price range calculation that displays only "good" numbers on axis (1, 2, 5, 10, 25, 50 * 10^2n and their multipliers)
|
static java.util.Map<java.lang.String,Layer1PriceAxisRangeCalculatable.ResultPriceAxisInfo> |
getGoodNumbersCalculation(double linesCount,
java.util.Map<java.lang.String,Layer1PriceAxisRangeCalculatable.InputPriceAxisInfo> inputInfo)
Invokes
getGoodNumbersCalculation(double, double, double) for every map entry |
static CalculatePricesResult |
getGoodNumbersPriceResult(double minValue,
double maxValue,
double linesCount)
Same as
getGoodNumbersCalculation(double, double, double), different return typeYou don't need to use this method unless you want to see advanced parameters of best solution |
public static final int[] PRICES_STEPS_MULTIPLIERS
public static final int MAX_POSITIVE_PRICES_STEPS_MULTIPLIER_POWER
public static final int MAX_NEGATIVE_PRICES_STEPS_MULTIPLIER_POWER
public static Layer1PriceAxisRangeCalculatable.ResultPriceAxisInfo getGoodNumbersCalculation(double minValue, double maxValue, double linesCount)
minValue - minimal value of indicator on chart rangemaxValue - maximum value of indicator on chart rangelinesCount - number of visible horizontal lines, that can display labels. Note that this value is double.public static java.util.Map<java.lang.String,Layer1PriceAxisRangeCalculatable.ResultPriceAxisInfo> getGoodNumbersCalculation(double linesCount, java.util.Map<java.lang.String,Layer1PriceAxisRangeCalculatable.InputPriceAxisInfo> inputInfo)
getGoodNumbersCalculation(double, double, double) for every map entrypublic static CalculatePricesResult getGoodNumbersPriceResult(double minValue, double maxValue, double linesCount)
getGoodNumbersCalculation(double, double, double), different return typeminValue - minimal value of indicator on chart rangemaxValue - maximum value of indicator on chart rangelinesCount - number of visible horizontal lines, that can display labels. Note that this value is double.