eclipse plugin: Add a TODO and refactor a bit the 'getConfig' method
This commit is contained in:
parent
7851271c91
commit
d5b38b549d
1 changed files with 8 additions and 3 deletions
|
@ -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;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Reference in a new issue