Class IntegerDescriptor
java.lang.Object
com.motivewave.platform.sdk.common.desc.SettingDescriptor<Integer>
com.motivewave.platform.sdk.common.desc.IntegerDescriptor
Describes an integer value that is used to configure a study/strategy.
-
Constructor Summary
ConstructorsConstructorDescriptionIntegerDescriptor
(String name, String label, int defaultValue, int minValue, int maxValue, int step) Constructor. -
Method Summary
Modifier and TypeMethodDescriptionjavafx.scene.Node
createInputFX
(Settings settings, boolean readOnly) Creates the component that will accept the user input.Gets the default value as an Integer.int
Gets the maximum value for the setting.int
Gets the minimum value for the setting.int
getStep()
Gets the step increment value.Methods inherited from class com.motivewave.platform.sdk.common.desc.SettingDescriptor
createInput, createTBInput, getDescription, getGridWidth, getHelpLink, getIconFactory, getId, getLabel, getName, isAllowUserDefaults, isDisplaySetting, isEnabled, isShowLabel, isSupportsDisable, setAllowUserDefaults, setDefaultValue, setDescription, setEnabled, setGridWidth, setHelpLink, setIconFactory, setShowLabel, setSupportsDisable
-
Constructor Details
-
IntegerDescriptor
public IntegerDescriptor(String name, String label, int defaultValue, int minValue, int maxValue, int step) Constructor.- Parameters:
name
- name of this setting (key)label
- label displayed to the userdefaultValue
- default integer valueminValue
- minimum integer valuemaxValue
- maximum integer valuestep
- step increment
-
-
Method Details
-
getDefaultValue
Gets the default value as an Integer.- Overrides:
getDefaultValue
in classSettingDescriptor<Integer>
- Returns:
- default value for the setting
-
createInputFX
Description copied from class:SettingDescriptor
Creates the component that will accept the user input. This is called by the study framework.- Specified by:
createInputFX
in classSettingDescriptor<Integer>
- Parameters:
settings
- settings for the studyreadOnly
- true if the component should not accept user input- Returns:
- component that will accept user input.
-
getMinValue
public int getMinValue()Gets the minimum value for the setting. -
getMaxValue
public int getMaxValue()Gets the maximum value for the setting. -
getStep
public int getStep()Gets the step increment value. -
fromJson
- Overrides:
fromJson
in classSettingDescriptor<Integer>
-