Overview
It's not possible to generate a virtual OnPropertyChanged method right now.
On changing/changed method of property generated as partial.
I want to override changing/changed method by subclass.
API breakdown
None.
Usage example
[ObservableProperty(GenerateOnChanging = false, GenerateOnChanged = false, CallOnChanging = false, CallOnChanged = false)]
private partial string _fieldA;
[ObservableProperty(GenerateOnChanged = false)]
private partial string _fieldB;
protected virtual void OnFieldBChanged(string? oldValue, string newValue) { }
protected virtual void OnFieldBChanged(string value) { }
Breaking change?
No
Alternatives
[ObservableProperty]
private partial string _field;
partial void OnFieldChanged(string value)
{
OnFieldChanged2(value);
}
protected virtual void OnFieldChanged2(string value) { }
Additional context
No response
Help us help you
Yes, I'd like to be assigned to work on this item
Overview
It's not possible to generate a virtual OnPropertyChanged method right now.
On changing/changed method of property generated as partial.
I want to override changing/changed method by subclass.
API breakdown
None.
Usage example
Breaking change?
No
Alternatives
Additional context
No response
Help us help you
Yes, I'd like to be assigned to work on this item