useObject
A useObject says when a discretionary solution tier may be
reached for a stop type. The rule is the accessibility condition; the thresholds then cap how much
ordinary supply may already exist before the tier is allowed at all.
-
ruleuseCondition - The accessibility condition — when the tier is reachable.
-
idleThresholdintegerdefaultnull - The tier may be used only while no more than this many IDLE solutions exist in the context space. 0 = only when there is no idle solution at all; null = the idle count is not tested.
-
reliableThresholdintegerdefaultnull - The tier may be used only while no more than this many RELIABLE solutions exist in the context space. 0 = only when there is no reliable solution at all; null = the reliable count is not tested.
Rule and thresholds
Section titled “Rule and thresholds”The two parts are independent tests, and both must pass:
- the
rule— a useCondition — decides whether the tier is reachable for this stop in principle (never, only when nothing economical solves it, only when it arrives earlier, at any time, and so on); - the thresholds decide whether the tier is reachable right now, by counting the ordinary solutions
already available in the stop’s context space. Spend is only released while that ordinary supply is
thin: at most
idleThresholdidle solutions and at mostreliableThresholdreliable ones.
A threshold of 0 is therefore the strictest setting — the tier opens only when the context space holds
no solution of that quality — and null switches the test off, leaving the rule alone in charge.
Example
Section titled “Example”"useExtended":{"rule":"INIT"},"useVoluntary":{"rule":"EARLIER"},"useSurge":{"rule":"LATE","idleThreshold":0}Extended time is available when booking a new project for immediate service; voluntary time when it buys an earlier arrival; surge only when the alternative is late and nothing idle is standing in the context space.
- The object form replaces the bare condition string (
"useSurge":"LATE"), which named the rule and nothing else. - It also replaces the separate
idleSurgeLimitstop parameter: the idle test now travels with the tier it gates, and applies to everyuse…parameter rather than to surge alone.
Related
Section titled “Related”- useCondition — the
rulevalues - stopParamsObject
- Concepts