pub fn descendants_of(
model: &Model,
root: EntityId,
) -> Result<Vec<EntityId>, CostRelationError>Expand description
Every descendant of a cost item, depth-first in authored order.
Excludes the root itself. Returns an error rather than looping if the file states a cycle or an unreasonably deep tree.
ยงErrors
CostRelationError::NestingCycle if an item is its own ancestor, or
CostRelationError::DepthExceeded past MAX_NESTING_DEPTH.