public abstract class FloatSignalSourceChooser extends AbstractSignalSourceChooser implements FloatSignalSource
float
that choose
dynamically from a fixed collection of inputs.Modifier and Type | Class and Description |
---|---|
(package private) static class |
FloatSignalSourceChooser.OfEnum<E extends Enum<E>> |
(package private) static class |
FloatSignalSourceChooser.OfEnumInt<E extends Enum<E>> |
(package private) static class |
FloatSignalSourceChooser.OfInt |
Constructor and Description |
---|
FloatSignalSourceChooser() |
Modifier and Type | Method and Description |
---|---|
protected abstract FloatSignalSource |
choose()
Returns the chosen the input signal source for the current
value.
|
protected Consumer<CompilationContext> |
compileDefaultValue()
Returns a code generator for loading the default value of the signal type
on the operand stack.
|
float |
getAsFloat()
Returns the current value of this signal source.
|
alwaysThrow, compileConvertToInt, compileDataFlow, compileOrDefault, getCases, getSelector
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
abs, add, choose, choose, choose, choose, clock, compileDataFlow, compileMainSignalSource, constant, defined, delayed, delayed, delayedFeedback, delayedFeedback, divide, equal, getConstantAsFloat, getValueClass, glidingAverage, glidingStandardDeviation, glidingSum, glidingVariance, greaterOrEqual, greaterThan, guard, hasConstantAsFloat, invariant, lessOrEqual, lessThan, map, max, min, modulo, multiply, negate, negative, nonEqual, nonnegative, nonpositive, nonzero, notANumber, positive, power, probe, publishStoredValueVariable, relateWith, sampleAndHold, selectAffine, series, sqrt, stored, subtract, zero, zeroCrossing, zipWith
compileDataFlowTo, hasDataFlowIO
protected abstract FloatSignalSource choose()
public float getAsFloat()
The value may be either computed on demand, or retrieved from storage.
Implementations of this method should have no side effect.
getAsFloat
in interface FloatSignalSource
getAsFloat
in interface FloatSupplier
protected Consumer<CompilationContext> compileDefaultValue()
AbstractSignalSourceChooser
compileDefaultValue
in class AbstractSignalSourceChooser