Package jmri.jmrit.logix
Class ThrottleSetting
java.lang.Object
jmri.jmrit.logix.ThrottleSetting
Oct 2020 - change formats to allow I18N of parameters
Jul 2024 - Add the SET_MEMORY action. This makes it possible to trigger external actions beyond just a sensor. DAS
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic classstatic enum -
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int(package private) static final int -
Constructor Summary
ConstructorsConstructorDescriptionThrottleSetting(long time, String cmdStr, String value, String beanName) ThrottleSetting(long time, String cmdStr, String value, String beanName, float trkSpd) ThrottleSetting(long time, ThrottleSetting.Command command, int key, String value, String beanName, float trkSpd) ThrottleSetting(long time, ThrottleSetting.Command command, int key, ThrottleSetting.ValueType vType, SpeedStepMode ss, float f, String tx, String beanName) ThrottleSetting(long time, ThrottleSetting.Command command, int key, ThrottleSetting.ValueType vType, SpeedStepMode ss, float f, String tx, String beanName, float trkSpd) -
Method Summary
Modifier and TypeMethodDescriptiongetBean()static ThrottleSetting.CommandgetCommandTypeFromInt(int typeInt) intNamedBeanHandle<? extends NamedBean>longgetTime()floatgetValue()protected static ThrottleSetting.CommandValuegetValueFromString(ThrottleSetting.Command command, String valueStr) static ThrottleSetting.ValueTypegetValueTypeFromInt(int typeInt) voidsetCommand(String cmdStr) voidsetCommand(ThrottleSetting.Command command) voidsetKeyNum(int key) setNamedBean(ThrottleSetting.Command cmd, String name) <T extends NamedBean>
voidvoidsetTime(long time) Time is an object so that a "synch to block entry" notation can be used rather than elapsed time.voidsetTrackSpeed(float s) voidvoidvoidsetValue(ThrottleSetting.ValueType t, SpeedStepMode s, float f, String tx) toString()
-
Field Details
-
CMD_SPEED
- See Also:
-
CMD_SPEEDSTEP
- See Also:
-
CMD_FORWARD
- See Also:
-
CMD_FTN
- See Also:
-
CMD_LATCH
- See Also:
-
CMD_NOOP
- See Also:
-
CMD_SET_SENSOR
- See Also:
-
CMD_WAIT_SENSOR
- See Also:
-
CMD_RUN_WARRANT
- See Also:
-
CMD_SET_MEMORY
- See Also:
-
VALUE_FLOAT
- See Also:
-
VALUE_NOOP
- See Also:
-
VALUE_INT
- See Also:
-
VALUE_STEP
- See Also:
-
VALUE_TEXT
- See Also:
-
VALUE_TRUE
- See Also:
-
VALUE_FALSE
- See Also:
-
VALUE_ON
- See Also:
-
VALUE_OFF
- See Also:
-
VALUE_ACTIVE
- See Also:
-
VALUE_INACTIVE
- See Also:
-
IS_TRUE_FALSE
- See Also:
-
IS_ON_OFF
- See Also:
-
IS_SENSOR_STATE
- See Also:
-
-
Constructor Details
-
ThrottleSetting
public ThrottleSetting() -
ThrottleSetting
public ThrottleSetting(long time, ThrottleSetting.Command command, int key, ThrottleSetting.ValueType vType, SpeedStepMode ss, float f, String tx, String beanName) -
ThrottleSetting
public ThrottleSetting(long time, ThrottleSetting.Command command, int key, ThrottleSetting.ValueType vType, SpeedStepMode ss, float f, String tx, String beanName, float trkSpd) -
ThrottleSetting
-
ThrottleSetting
-
ThrottleSetting
public ThrottleSetting(long time, ThrottleSetting.Command command, int key, String value, String beanName, float trkSpd) -
ThrottleSetting
-
-
Method Details
-
getCommandTypeFromInt
-
getValueTypeFromInt
-
getValueFromString
protected static ThrottleSetting.CommandValue getValueFromString(ThrottleSetting.Command command, String valueStr) throws JmriException - Throws:
JmriException
-
setTime
Time is an object so that a "synch to block entry" notation can be used rather than elapsed time.- Parameters:
time- the time in some unit
-
getTime
-
setCommand
-
setCommand
-
getCommand
-
setKeyNum
-
getKeyNum
-
setValue
-
setValue
-
setValue
-
getValue
-
setTrackSpeed
-
getTrackSpeed
-
setNamedBean
-
setNamedBeanHandle
-
getNamedBeanHandle
-
getBean
-
getBeanDisplayName
-
getBeanSystemName
-
toString
-