|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.util.Observable
uk.org.toot.control.Control
uk.org.toot.control.LawControl
public class LawControl
A LawControl enables control of a float value using the specified control law.
Constructor Summary | |
---|---|
LawControl(int id,
java.lang.String name,
ControlLaw law,
float precision,
float initialValue)
|
Method Summary | |
---|---|
void |
applyPreset(java.lang.String name)
|
java.awt.Color |
getInsertColor()
|
int |
getIntValue()
|
ControlLaw |
getLaw()
|
float |
getPrecision()
Obtains the precision or granularity of the control, in the units that the control measures. |
java.lang.String[] |
getPresetNames()
|
float |
getValue()
Obtains this control's current value. |
java.lang.String |
getValueString()
override for real value strings where possible |
void |
setInsertColor(java.awt.Color insertColor)
|
void |
setIntValue(int value)
|
void |
setValue(float value)
Sets the current value for the control. |
Methods inherited from class uk.org.toot.control.Control |
---|
getAnnotation, getControlPath, getControlPath, getId, getName, getParent, isAdjusting, isEnabled, isHidden, isIndicator, setAdjusting, setAnnotation, setEnabled, setHidden, setName, toString |
Methods inherited from class java.util.Observable |
---|
addObserver, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public LawControl(int id, java.lang.String name, ControlLaw law, float precision, float initialValue)
Method Detail |
---|
public ControlLaw getLaw()
public float getValue()
public java.lang.String getValueString()
Control
getValueString
in class Control
public void setValue(float value)
value
- the desired new value
java.lang.IllegalArgumentException
- if the value indicated does not fall within the allowable rangepublic float getPrecision()
public java.awt.Color getInsertColor()
public void setInsertColor(java.awt.Color insertColor)
public void setIntValue(int value)
setIntValue
in class Control
public int getIntValue()
getIntValue
in class Control
public java.lang.String[] getPresetNames()
public void applyPreset(java.lang.String name)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |