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 defaulting of non-"false" QueryOption fields to "true" #2420

Open
wants to merge 9 commits into
base: integration
Choose a base branch
from

Conversation

SethSmucker
Copy link
Collaborator

  • Create function evaluateBooleanOption() method in QueryOptions
  • Use evaluateBooleanOption() in the validateOptions() method
  • Add a test in QueryOptionsTest to test evaluateBooleanOption()

resolves #2410

- Create function evaluateBooleanOption() method in QueryOptions
- Use evaluateBooleanOption() in the validateOptions() method
- Add a test in QueryOptionsTest to test evaluateBooleanOption()

resolves #2410
* @return True if the option is null or not "false". False if the option has the value "false" (not case-sensitive).
*/
private static boolean evaluateBooleanOption(String value) {
if (value == null) {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, this is great. Now we need to add the second part of the ticket which is to update the DefaultQueryPlanner which is setting up these options to use null values instead of "true" when setting up these options on the iterator.

@@ -20,6 +20,7 @@
import java.util.List;
import java.util.Map;
import java.util.Map.Entry;
import java.util.Objects;
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unused import

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

Successfully merging this pull request may close these issues.

Tighter query options
4 participants