/**
* Answers the set of distinct feature types for which there is at least one
- * feature with the given feature group
+ * feature with one of the given feature group(s)
*
- * @param group
+ * @param groups
* @return
*/
- public Set<String> getFeatureTypesForGroup(String group)
+ public Set<String> getFeatureTypesForGroups(String... groups)
{
Set<String> result = new HashSet<String>();
for (Entry<String, FeatureStore> featureType : featureStore.entrySet())
{
- if (featureType.getValue().getFeatureGroups().contains(group))
+ Set<String> featureGroups = featureType.getValue().getFeatureGroups();
+ for (String group : groups)
{
- /*
- * yes this feature type includes the query group
- */
- result.add(featureType.getKey());
+ if (featureGroups.contains(group))
+ {
+ /*
+ * yes this feature type includes a query group
+ */
+ result.add(featureType.getKey());
+ break;
+ }
}
}