What difference between Revert and MarkAsClean methods.
BekAllaev opened this issue · 1 comments
public PersonProxy TempPerson
{
set { Set(ref proxyPerson, value); }
get { return proxyPerson; }
}
PersonProxy
inhereted by ValidatableModelBase
. I were thinking about how I can set IsDirty
to false if TempPerson
become dirty. And have solved this by MarkAsClean
method but at the same time I have noticed that Revert
method also may change IsDirty
value to false. So when I used breakpoint and checked value of TempPerson
properties after I have called MarkAsClean
and made same action for Revert
method and I saw that only thing that this methods do is changing IsDirty
property, while other properties stay the same. So the result of this methods I can see by the situation that I have described before so explain me please what this methods must to do cause there must not be two methods that do the same procedure.
Revert returns the Value to the OriginalValue.
MarkAsClean sets the OriginalValue to the current Value.