![]() |
Synthia
Generic and flexible data structure generator
|
Interface implemented by pickers whose picking of objects can be altered by external information.
To this end, a reactive picker provides a method called tell, which is used to pass an object that the picker may use to modify its internal state or the way the next value will be produced.
A simple example of a reactive picker is RandomInteger; in this case, method tell is used to modify the upper bound of its range of possible values. RandomBoolean uses tell to modify the probability of producing value true, and PoissonInteger uses it to modify its parameter λ.
Reactive pickers are especially useful in the context of testing of an interactive component, such as a user interface.
| <T> | The type of objects returned by the picker |
| <U> | The type of objects used in a notification to the picker |
Definition at line 43 of file Reactive.java.

Public Member Functions | |
| void | tell (U u) |
| Notifies a picker of some external information. More... | |
Public Member Functions inherited from ca.uqac.lif.synthia.Picker< T > | |
| void | reset () |
| Puts the picker back into its initial state. More... | |
| T | pick () |
| Picks an object. More... | |
| Picker< T > | duplicate (boolean with_state) |
| Creates a copy of the picker. More... | |
| void ca.uqac.lif.synthia.Reactive< U, T >.tell | ( | U | u | ) |
Notifies a picker of some external information.
| u | The information |