Is there a hierotics to find class invariants, I mean
- Never trust ...;
Perhaps this is the usual advice.
Any links on paper where real-life examples are studied
Classes are very different from each other, it may be difficult to come by the scientists. Although there will be a lot of theories for the special style of the classes. For example, each design pattern has uncontrolled sets of its own.
The best and easiest way to achieve your goals is to understand how your class is perceived [or if you do TDD, test the tests], and understand that for those specifications The conditions must be correct to be implemented correctly. In other words, you "push your specifications through your code" as you do so, they will appear 'irreversible' which are encountering in front of you.
Note that sometimes it has to propagate pre-conditions, "to move forward through", sometimes it means that the expansion behind the previous situation means the spread. Often, both.
Comments
Post a Comment