I am curious how to make this work
Class<Map<String,String>> food = Map.class;
That obviously doesn't work. I would want something like this
Class<Map<String,String>> food = Map<String,String>.class;
but this seems like not a valid java sytax.
How can make this work?
EDIT: The reason I want this is because I have a method like this
protected <ConfigType> ConfigValue<ConfigType> getSectionConfig(String name, Class<ConfigType> configType) {
return config.getConfig(name);
}
I would like to call this as so
ConfigValue<Map<String,Object>> config = getSectionConfig("blah", Map<String,Object>.class>);
Map<String,Value> val = config.value();