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

Use native Iterator for RuleFilterer (and others) #72

Open
jclaveau opened this issue Dec 27, 2018 · 2 comments
Open

Use native Iterator for RuleFilterer (and others) #72

jclaveau opened this issue Dec 27, 2018 · 2 comments

Comments

@jclaveau
Copy link
Owner

jclaveau commented Dec 27, 2018

Just a really interesting optimization?

@jclaveau
Copy link
Owner Author

It's unexpected but SPL Iterators are slower than foreach() https://3v4l.org/lpCJo

Splitting the Filterer between Iterator and the behaviors to apply on each element would be interesting btw
https://refactoring.guru/design-patterns/iterator

@jclaveau
Copy link
Owner Author

jclaveau commented Apr 8, 2019

A RuleTreeIterator would be nice for single responsability https://evolvingweb.ca/blog/iterating-over-trees-php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant