A
A
Alex2011-03-15 18:48:59
C++ / C#
Alex, 2011-03-15 18:48:59

What is the name of the antipattern when a property changes value when assigned?

Code like this

public int Size { get { return _size; } set { _size = value + 15; } }<br/>

What is it called correctly? Thank you.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
J
JeanLouis, 2011-03-15
@JeanLouis

Not everything has a name, come up with a name yourself, like "Broken Phone".

A
Anatoly, 2011-03-15
@taliban

What's wrong with changing a property with a setter?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question