Skip to content

Conversation

@m1nus0ne
Copy link

@m1nus0ne m1nus0ne commented Nov 5, 2024

No description provided.

new Person("Vasili III of Russia", 28, 170, 60, null));

// Какие недостатки у такого подхода?
//Проблема с читаемостью, необходимость обновлять метод AreEqual при изменении сигнатуры Person

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

А можешь в этом треде подробнее раскрыть, что ты имеешь в виду под читаемостью и под изменением сигнатуры?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

При изменении/добавлении полей возникает необходимость переписывание метода AreEqual, сравнение ннго количества полей менне читаемое решение, чем сравнивание всех полей исключая поле Id ()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants