### Question:
MapInjectionResolver extends InjectionResolver<Param> { @Override public <V> V getValue(Object component, AnnotatedElement target, Type genericType, Class<V> type) throws MultiException { Param param = target.getAnnotation(Param.class); String paramName = CommandModel.getParamName(param, target); if (param.primary()) { List<String> value = parameters.get("DEFAULT"); if (value != null && value.size() > 0) { final List<String> filePaths = getUploadedFileParamValues( "DEFAULT", type, optionNameToUploadedFileMap); if (filePaths != null) { value = filePaths; parameters.set("DEFAULT", value); } else { for (String s : value) { checkAgainstAcceptableValues(target, s); } } parameters.set(paramName, value); V paramValue = (V) convertListToObject(target, type, value); return paramValue; } } if (param.multiple()) { List<String> value = parameters.get(paramName); if (value != null && value.size() > 0) { final List<String> filePaths = getUploadedFileParamValues( paramName, type, optionNameToUploadedFileMap); if (filePaths != null) { value = filePaths; parameters.set(paramName, value); } else { for (String s : value) { checkAgainstAcceptableValues(target, s); } } } parameters.set(paramName, value); V paramValue = (V) convertListToObject(target, type, value); return paramValue; } String paramValueStr = getParamValueString(parameters, param, target, context); final String fileParamValueStr = getUploadedFileParamValue( paramName, type, optionNameToUploadedFileMap); if (fileParamValueStr != null) { paramValueStr = fileParamValueStr; parameters.set(paramName, paramValueStr); } checkAgainstAcceptableValues(target, paramValueStr); return paramValueStr != null ? (V) convertStringToObject(target, type, paramValueStr) : (V) getParamField(component, target); } MapInjectionResolver(CommandModel model,
					ParameterMap parameters);  MapInjectionResolver(CommandModel model,
					ParameterMap parameters,
                                        final MultiMap<String,File> optionNameToUploadedFileMap); void setContext(ExecutionContext context); @Override boolean isOptional(AnnotatedElement element, Param annotation); @Override V getValue(Object component, AnnotatedElement target, Type genericType, Class<V> type); static String getUploadedFileParamValue(final String fieldName,
                final Class fieldType,
                final MultiMap<String,File> optionNameToFileMap); static List<String> getUploadedFileParamValues(
                final String fieldName,
                final Class fieldType,
                final MultiMap<String,File> optionNameToFileMap); static Object convertListToObject(AnnotatedElement target,
                                    Class type, List<String> paramValList); static final LocalStringManagerImpl localStrings; }### Answer:
@Test public void getParamValueTest() { try { DummyCommand dc = new DummyCommand(); Class<?> cl = dc.getClass(); ParameterMap params = new ParameterMap(); params.add("hello", "world"); CommandModel dccm = new CommandModelImpl(dc.getClass()); MapInjectionResolver mir = new MapInjectionResolver(dccm, params); AnnotatedElement ae = (AnnotatedElement)cl.getDeclaredField("hello"); String hello = mir.getValue(dc, ae, null, String.class); assertEquals("hello should be world", "world", hello); } catch (Exception ex) { ex.printStackTrace(); fail("unexpected exception"); } }