danielferber/infra4j — Issue #1: Bind system rules/invariants to IllegalControlStateExceptions
Author: danielferber
Created: 2012-01-20 17:27:52+00:00
State: open

I am wondering if it would be beneficial to bind the IllegalControlStateExceptions to enumerations that identify system rules or invariants. This would allow one to recongnize, if a IllegalControlStateException is thrown, what system rule or invariant was not satisfied.

Even more, if a careful programmers always checks a system rule/invariant on each code point that depends on the rule/invariant, then a search for the enum constant will reveal all code points that are affected by the rule or invariant.