AssignTarget#
A category of slot that Project::suggest_assignments acts on. Each slot falls into exactly one category, judged from its current resource in the accepted state. List the categories to act on in SuggestOptions::targets, in any combination, each at most once.
Declaration#
Variants#
| Variant | Description |
|---|---|
Empty |
The slot has no assignment. Targeting it fills the slot in pass 0. |
Broken |
The slot's resource isn't in the slot's allowed list. Targeting it repairs the slot in pass 0 with the cheapest candidate, whatever keeping the current resource would cost. |
Valid |
The slot's resource is in allowed. Targeting it rebalances the slot in passes 1..=passes. The resource changes only on a strict improvement. |
For the default and the report-only setting, see SuggestOptions::targets. For how the passes run, see Suggesting assignments.
Example#
use ;
Related#
SuggestOptions- holds the list of targeted categories intargetsSlot- the input whose state decides its categorySuggestResult- reports which targeted slots stayed unfilled or invalid- Suggesting assignments - shows filling, rebalancing and repairing with each target