ProcessorConfig { public String getConfig(String name, String key) { TreeMap processorMap = config.get(name); return processorMap != null ? (String) processorMap.get(key) : null; } ProcessorConfig();  ProcessorConfig(List<String> includes, Set<String> excludes, Map<String, TreeMap> config); String getConfig(String name, String key); Map<String, String> getConfigMap(String name); List<T> prepareProcessors(List<T> namedList, String type); boolean use(String inc); static ProcessorConfig cloneProcessorConfig(ProcessorConfig processorConfig); static ProcessorConfig mergeProcessorConfigs(ProcessorConfig ... processorConfigs); static final ProcessorConfig EMPTY; }
@Test public void config() { ProcessorConfig pConfig = new ProcessorConfig(null, null, config); assertEquals("v1", pConfig.getConfig("k1", "i1")); assertNull(pConfig.getConfig("k2", "i1")); assertNull(pConfig.getConfig("k1", "i2")); }