kswoll / ReactiveUI.Fody

C# Fody extension to generate RaisePropertyChange notifications for properties and ObservableAsPropertyHelper properties.
MIT License
154 stars 31 forks source link

Reactive Attribute suggestion #3

Closed jcmm33 closed 9 years ago

jcmm33 commented 9 years ago

Might be worth considering adding a parameter to reactive attribute to specify the access modifier for the set property . We have a few scenarios whereby the setting of the property value is internal to the view model and shouldn't be settable by 'outside' classes e.g.

public int Value2 { get { return _value2; } private set { this.RaiseAndSetIfChanged(ref _value2, value); } }
kswoll commented 9 years ago

Hmm, can't you already do this?

[Reactive]public int Value2 { get; private set; }

That seems to work for me.

jcmm33 commented 9 years ago

Sorry, its me being completely stupid.

kswoll commented 9 years ago

Lol, no worries. :)