public class NormalizedParameter extends Object implements LXNormalizedParameter
LXParameter.Formatter, LXParameter.Polarity, LXParameter.Units
Constructor and Description |
---|
NormalizedParameter(String label) |
NormalizedParameter(String label,
double value) |
Modifier and Type | Method and Description |
---|---|
void |
dispose()
Invoked when the parameter is done being used and none of its resources
are needed anymore.
|
String |
getDescription()
Returns a contextual help message explaining the purpose of this parameter to the user, or null if
none is available.
|
double |
getExponent()
Gets the exponent used for scaling this parameter across its normalized range.
|
LXParameter.Formatter |
getFormatter()
Gets the formatter to be used for printing this parameter's value
|
String |
getLabel()
Gets the label for this parameter
|
double |
getNormalized()
Gets the value of the parameter in a normalized space from 0 to 1
|
float |
getNormalizedf()
Gets the value of the parameter in a normalized space as a float
|
LXComponent |
getParent()
Returns the component that this object belongs to
|
String |
getPath()
Returns the immediate path of this component, relative to its parent
|
LXParameter.Polarity |
getPolarity()
Gets the polarity of this parameter.
|
LXParameter.Units |
getUnits()
Gets the unit format that this parameter's value stores.
|
double |
getValue()
Retrieves the value of the parameter
|
float |
getValuef()
Utility helper function to get the value of the parameter as a float.
|
boolean |
isMappable()
Whether this parameter should be eligible for mapping via MIDI or
modulation control.
|
NormalizedParameter |
reset()
A method to reset the value of the parameter, if a default is available.
|
NormalizedParameter |
setComponent(LXComponent component,
String path)
Sets the component that owns this parameter
|
NormalizedParameter |
setDescription(String description) |
NormalizedParameter |
setNormalized(double value)
Sets the value or the parameter in normalized space from 0 to 1
|
NormalizedParameter |
setValue(double value)
Sets the value of the parameter.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
setMappable
get, get, getCanonicalLabel, getCanonicalLabel, getCanonicalPath, getCanonicalPath, getComponent, getComponent, getParameter, getParameter
public NormalizedParameter(String label)
public NormalizedParameter(String label, double value)
public NormalizedParameter setComponent(LXComponent component, String path)
LXParameter
setComponent
in interface LXParameter
component
- Componentpath
- Path name for parameterpublic LXComponent getParent()
LXPath
public String getPath()
LXPath
public NormalizedParameter setDescription(String description)
public String getDescription()
LXParameter
getDescription
in interface LXParameter
public LXParameter.Formatter getFormatter()
LXParameter
getFormatter
in interface LXParameter
public LXParameter.Units getUnits()
LXParameter
getUnits
in interface LXParameter
public LXParameter.Polarity getPolarity()
LXParameter
getPolarity
in interface LXParameter
public void dispose()
LXParameter
dispose
in interface LXParameter
public NormalizedParameter reset()
LXParameter
reset
in interface LXParameter
public NormalizedParameter setValue(double value)
LXParameter
setValue
in interface LXParameter
value
- The valuepublic double getValue()
LXParameter
getValue
in interface LXParameter
public float getValuef()
LXParameter
getValuef
in interface LXParameter
public String getLabel()
LXParameter
getLabel
in interface LXPath
getLabel
in interface LXParameter
public NormalizedParameter setNormalized(double value)
LXNormalizedParameter
setNormalized
in interface LXNormalizedParameter
value
- The normalized value, from 0 to 1public double getNormalized()
LXNormalizedParameter
getNormalized
in interface LXNormalizedParameter
public float getNormalizedf()
LXNormalizedParameter
getNormalizedf
in interface LXNormalizedParameter
public double getExponent()
LXNormalizedParameter
getExponent
in interface LXNormalizedParameter
public boolean isMappable()
LXParameter
isMappable
in interface LXParameter
true
if mappable, false if otherwiseLX library by Mark C. Slee. © 2012-2020