Github user ellisonanne commented on a diff in the pull request:
https://github.com/apache/incubator-pirk/pull/26#discussion_r72371135
--- Diff: src/main/java/org/apache/pirk/schema/query/QuerySchemaLoader.java
---
@@ -246,8 +231,11 @@ private static QuerySchema loadQuerySchemaFile(String
schemaFile, boolean hdfs,
}
// Create the query schema object
- querySchema = new QuerySchema(schemaName, dataSchemaName,
elementNames, selectorName, dataElementSize, filterNamesSet, filter);
+ DataFilter filter = instantiateFilter(filterTypeName, filterNamesSet);
+ querySchema = new QuerySchema(schemaName, dataSchemaName,
selectorName, filterTypeName, filter, dataElementSize);
--- End diff --
As a very small (kind of nitty) style item, I would much rather have setter
methods for QuerySchema to set the `elementName` and `filterNamesSet` rather
than setting these fields via
```
querySchema.getElementNames().addAll(elementNames);
querySchema.getFilteredElementNames().addAll(filterNamesSet);
```
In the original code, these were passed in as part of the constructor
(which has now been removed in this refactor).
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---