Extends the API of ObservableCollection by inheriting from MutableSequence#38
Merged
theodox merged 2 commits intotheodox:remove_keysfrom Oct 12, 2016
Merged
Conversation
…uence, which gives it most of the standard methods found on list. I also went ahead and added a reverse method, which for some reason is not on the MutableSequence abstract class. This made it a lot easier to teach others how to work with the collections, as they could just reuse what they knew about manipulating lists. The original API was left in place, and all tests continue to pass. Also extended the API of BoundCollection by inheriting from Sequence, which makes it more tuple-like.
Forgot to include this last night. Added a test for the new reverse method, and updated the sort test to have unsorted content at the start, and actually call the primary sort method before calling with the reverse flag.
Owner
|
I'm pulling this into remove_keys, I'll try it out that way and merge it sideways. I want to make sure I understand how it fires the update events |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This made it a lot easier to teach others how to work with the collections, as they could just reuse what they knew about manipulating lists.
I also went ahead and added a reverse method, which for some reason is not on the MutableSequence abstract class. Though it looks like they fixed this somewhere along the lines for Py3.
The original API was left in place, and all tests continue to pass.
Also extended the API of BoundCollection by inheriting from Sequence, which makes it more tuple-like.