eclipse plugin: Add a TODO and refactor a bit the 'getConfig' method

This commit is contained in:
Timotei Dolean 2011-07-07 21:03:54 +00:00
parent 7851271c91
commit d5b38b549d

View file

@ -156,6 +156,7 @@ public class ProjectCache
return properties_;
}
//TODO: memorize the full project-relative path for the config file!
/**
* Gets the map with the Configs
* The key represent the filenames of the files
@ -175,9 +176,13 @@ public class ProjectCache
*/
public ConfigFile getConfig(String name)
{
if (configFiles_.containsKey(name) == false)
configFiles_.put(name, new ConfigFile(name));
return configFiles_.get(name);
ConfigFile config = configFiles_.get( name );
if ( config == null ){
config = new ConfigFile( name );
configFiles_.put( name, config );
}
return config;
}
/**