-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Remove the IList from IReactiveList<T> #430
Conversation
This should not have been on the generic interface. It only belongs to the generic implementation. Fixes #427
…ces-fix Remove the IList from IReactiveList<T>
✨ ✨ ✨ ✨ ✨ ✨ ✨ ✨ |
Mmm, the fact that we lose ICollection looks strange to me. Maybe we should make
That would result in this: public interface IReactiveCollection : ICollection, IReactiveNotifyCollectionChanged, IReactiveNotifyCollectionItemChanged, INotifyPropertyChanging, INotifyPropertyChanged, IEnableLogger
{
}
public interface IReactiveCollection<T> : ICollection<T>, IReactiveNotifyCollectionChanged<T>, IReactiveNotifyCollectionItemChanged<T>, IEnableLogger
{
}
public interface IReactiveList<T> : IReactiveCollection<T>, IList<T>
{
}
public interface IReactiveList : IReactiveCollection, IList
{
}
public class ReactiveList<T> : IReactiveList<T>, IReactiveList, IReadOnlyReactiveList<T>
{
} What do you think about this? I will create a pull request but I am curious what you guys think about this change before I create one. |
Nah, there's a very good reason for this that actually maps to BCL types It may well be the real "problem" is On Tuesday, December 10, 2013, Johan Laanstra wrote:
|
Yeah, perhaps a better name for In a way, this is analogous to how However, if we could redo the base interfaces, I would probably make add an However, this wasn't done that way because the read only stuff came later. Long story short, I think it'll be way more common that we'll have APIs that want to be able to handle any reactive collection (aka |
I modified my proposal and created a PR to move the discussion to its own thread #432. |
I was not aware of this, but it makes sense in that case.
The way I understand the readonly BCL interfaces naming, is that IReadOnlyEnumerable was a silly name and they therefore chose |
Heh, that was my reasoning as well for |
This should not have been on the generic interface. It only belongs to
the generic implementation.
Fixes #427