List of usage examples for org.apache.solr.common.util NamedList forEach
public void forEach(BiConsumer<String, T> action)
From source file:uk.co.flax.biosolr.FacetTreeParameters.java
License:Apache License
/** * Construct the tree parameters from the arguments passed to the * component.//from www . ja v a 2 s .c o m * @param args the arguments passed to the component. */ public FacetTreeParameters(NamedList<? extends Object> args) { // Find "defaults" list @SuppressWarnings({ "unchecked", "rawtypes" }) NamedList<? extends Object> defaultArgs = (NamedList) args.get(PluginInfo.DEFAULTS); if (defaultArgs != null) { // Assume all of the args are single strings for now defaultArgs.forEach(entry -> { defaults.put(entry.getKey(), (String) entry.getValue()); }); } }