Is it possible to tell the deserializer (via e.g. ContractResolver) to write the value of a Property directly to its internal or private backing field instead of using its setter?
Model:
public class TestModel
{
public string Name
{
get => _Name;
set
{
// do some very expensive stuff
_Name = value;
}
}
internal string _Name = string.Empty;
}
So my expectation is, that after some magic code the Deserializer writes the value for Property "Name" to the field "_Name" and avoid the expensive extra work done in setter of the Name prop.