Demeter's Law Breaking Search Tool?

Does anyone know a tool that I could use with the C # application to find possible violations of the Demeter Law? I know that this will give a lot of false positives, but I think it can be useful. Especially during the early design process.

+3
source share
1 answer

If you are just looking something.somethingelse.violation, you can use Visual Studio.

In the search dialog box, select the Use box and select Regular Expressions.

Not very reliable, but you can use <[:a_]+\.([:a_]+\.)+[:a_]+to find the template above.

grep , , lookbehind, , using namespace.

grep Windows

, .NET-, .cs / .vb , .NET Regex, , , , VS .

+4

Source: https://habr.com/ru/post/1759175/


All Articles