com.dukascopy.api.indicators
Class DoubleRangeDescription

java.lang.Object
  extended by com.dukascopy.api.indicators.DoubleRangeDescription
All Implemented Interfaces:
OptInputDescription

public class DoubleRangeDescription
extends Object
implements OptInputDescription

Describes optional input as range of values

Author:
Dmitry Shohov

Constructor Summary
DoubleRangeDescription()
          Creates object without setting any field
DoubleRangeDescription(double defaultValue, double min, double max, double suggestedIncrement, int precision)
          Creates object and sets all the fields
 
Method Summary
 double getDefaultValue()
          Returns default value, that is used if user doesn't set optional input
 double getMax()
          Returns maximal value
 double getMin()
          Returns minimal value
 int getPrecision()
          Returns number of digits after decimal separator, that should be used
 double getSuggestedIncrement()
          Returns suggested step to change this input
 void setDefaultValue(double defaultValue)
          Sets default value, that is used if user doesn't set optional input
 void setMax(double max)
          Sets maximal value
 void setMin(double min)
          Sets minimal value
 void setPrecision(int precision)
          Sets number of digits after decimal separator, that should be used
 void setSuggestedIncrement(double suggestedIncrement)
          Sets suggested step to change this input
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DoubleRangeDescription

public DoubleRangeDescription()
Creates object without setting any field


DoubleRangeDescription

public DoubleRangeDescription(double defaultValue,
                              double min,
                              double max,
                              double suggestedIncrement,
                              int precision)
Creates object and sets all the fields

Parameters:
defaultValue - default value, that is user if used doesn't set optional input
min - minimal value
max - maximal value
suggestedIncrement - suggested step to change this input
precision - number of digits after decimal separator
Method Detail

getDefaultValue

public double getDefaultValue()
Returns default value, that is used if user doesn't set optional input

Returns:
default value

setDefaultValue

public void setDefaultValue(double defaultValue)
Sets default value, that is used if user doesn't set optional input

Parameters:
defaultValue - default value

getMin

public double getMin()
Returns minimal value

Returns:
minimal value

setMin

public void setMin(double min)
Sets minimal value

Parameters:
min - minimal value

getMax

public double getMax()
Returns maximal value

Returns:
maximal value

setMax

public void setMax(double max)
Sets maximal value

Parameters:
max - maximal value

getSuggestedIncrement

public double getSuggestedIncrement()
Returns suggested step to change this input

Returns:
suggested step to change this input

setSuggestedIncrement

public void setSuggestedIncrement(double suggestedIncrement)
Sets suggested step to change this input

Parameters:
suggestedIncrement - suggested step to change this input

getPrecision

public int getPrecision()
Returns number of digits after decimal separator, that should be used

Returns:
number of digits after decimal separator, that should be used

setPrecision

public void setPrecision(int precision)
Sets number of digits after decimal separator, that should be used

Parameters:
precision - number of digits after decimal separator, that should be used


Copyright © 2009. All Rights Reserved.