Given zero or more step functions, evaluates them only for times before a $T$ time units have elapsed from the start of the run.
(t, *step_funcs)
| 5177 | |
| 5178 | |
| 5179 | def before_time(t, *step_funcs): |
| 5180 | """ |
| 5181 | Given zero or more step functions, evaluates them only for times before a $T$ time |
| 5182 | units have elapsed from the start of the run. |
| 5183 | """ |
| 5184 | |
| 5185 | def _before_t(sim): |
| 5186 | return sim.round_time() < t |
| 5187 | |
| 5188 | return _when_true_funcs(_before_t, *step_funcs) |
| 5189 | |
| 5190 | |
| 5191 | def during_sources(*step_funcs): |
nothing calls this directly
no test coverage detected