Skip to content
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

Add __iter__ method to Dataset #1351

Closed
kvjrhall opened this issue Jul 4, 2021 · 1 comment · Fixed by #1382
Closed

Add __iter__ method to Dataset #1351

kvjrhall opened this issue Jul 4, 2021 · 1 comment · Fixed by #1382
Labels
good first issue Good for newcomers

Comments

@kvjrhall
Copy link
Contributor

kvjrhall commented Jul 4, 2021

Motivation

It is convenient to be able to iterate over all triples in a Graph instance without invoking graph.triples((None, None, None)). When working with a small instance of Dataset, there are occasions where one will want to observe all of the quads in a similar manner.

Notes

This is trivial to implement by simply having an introduced __iter__ method invoke self.quads((None, None, None, None)) in exactly the same way that it is done in Graph.

@nicholascar
Copy link
Member

This is trivial to implement…

Then please do submit a Pull Request for this! We can then review it the implementation causes an problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants