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

Attribute#getValues to return Iterable #39

Open
GoogleCodeExporter opened this issue May 13, 2015 · 1 comment
Open

Attribute#getValues to return Iterable #39

GoogleCodeExporter opened this issue May 13, 2015 · 1 comment

Comments

@GoogleCodeExporter
Copy link

Type-Enhancement

Please consider changing Attribute#getValues so it return Iterable, not List
As I can see, in most cases Iterable would be enough.

Original issue reported on code.google.com by g...@inbox.ru on 17 Dec 2014 at 1:09

@GoogleCodeExporter
Copy link
Author

Thanks, good suggestion. Fixed in trunk.

Originally (pre-release versions of) CQEngine did use Iterable here. The reason 
for requiring List was the algorithm in TupleCombinationGenerator (used by 
CompoundIndex). Most literature talks of Lists :) But on revisiting it today, 
the inner lists can actually be Iterable, so it was easier than expected to 
refactor.

Indeed this change can provide more flexibility and performance improvements in 
applications.

These changes are backward compatible with existing attributes at source code 
level, but they are not backward compatible with already-compiled attributes.

When applications upgrade to the next release of the library, existing 
attributes will need to be recompiled against the new Attribute interface; 
however no actual code changes in the attribute source will be necessary.

The changes are in trunk, but I will leave this issue open until the next 
release is out.

Original comment by ni...@npgall.com on 17 Dec 2014 at 6:20

  • Changed state: Started
  • Added labels: Type-Enhancement
  • Removed labels: Type-Defect

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