Class Random
java.lang.Object
com.marginallyclever.nodegraphcore.Node
com.marginallyclever.nodegraphcore.nodes.math.Random
public class Random extends Node
Generate a new random number in the range max-min when updated.
-
Field Summary
Fields inherited from class com.marginallyclever.nodegraphcore.Node
TITLE_HEIGHT
-
Constructor Summary
-
Method Summary
Methods inherited from class com.marginallyclever.nodegraphcore.Node
addVariable, cleanAllInputs, cleanAllOutputs, getInPosition, getLabel, getName, getNumVariables, getOutPosition, getRectangle, getUniqueID, getUniqueIDSource, getUniqueName, getVariable, getVariables, isDirty, moveRelative, removeVariable, setLabel, setPosition, setRectangle, setUniqueID, setUniqueIDSource, toString, updateBounds, updateIfNotDirty
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Constructor Details
-
Random
public Random(double top, double bottom)Constructor for subclasses to call.- Parameters:
top
- the maximum value, exclusive.bottom
- the minimum value, inclusive.
-
Random
public Random()Constructor for subclasses to call.
-
-
Method Details
-
create
Description copied from class:Node
Return one new instance of this type ofNode
. Override this method in derived classes. -
update
public void update()Description copied from class:Node
Override this method to provide the custom behavior of this node. Runs regardless of dirty inputs or outputs.
-