static Placement fromInt(int val) { if (val < 0 || val >= Placement.values.length) { throw StateError('Invalid numeric value $val for Placement enum.'); } return Placement.values[val]; }