This commit is contained in:
@@ -35,13 +35,30 @@ void SourceGroupSettingsWithJavaMaven::setShouldIndexMavenTests(bool value)
|
||||
m_shouldIndexMavenTests = value;
|
||||
}
|
||||
|
||||
FilePath SourceGroupSettingsWithJavaMaven::getMavenSettingsFilePath() const
|
||||
{
|
||||
return m_mavenSettingsFilePath;
|
||||
}
|
||||
|
||||
FilePath SourceGroupSettingsWithJavaMaven::getMavenSettingsFilePathExpandedAndAbsolute() const
|
||||
{
|
||||
return utility::getExpandedAndAbsolutePath(
|
||||
getMavenSettingsFilePath(), getProjectSettings()->getProjectDirectoryPath());
|
||||
}
|
||||
|
||||
void SourceGroupSettingsWithJavaMaven::setMavenSettingsFilePath(const FilePath& path)
|
||||
{
|
||||
m_mavenSettingsFilePath = path;
|
||||
}
|
||||
|
||||
bool SourceGroupSettingsWithJavaMaven::equals(const SourceGroupSettingsBase* other) const
|
||||
{
|
||||
const SourceGroupSettingsWithJavaMaven* otherPtr =
|
||||
dynamic_cast<const SourceGroupSettingsWithJavaMaven*>(other);
|
||||
|
||||
return (
|
||||
otherPtr && m_mavenProjectFilePath == otherPtr->m_mavenProjectFilePath &&
|
||||
otherPtr && m_mavenProjectFilePath == otherPtr->m_mavenProjectFilePath && otherPtr &&
|
||||
m_mavenSettingsFilePath == otherPtr->m_mavenSettingsFilePath &&
|
||||
m_shouldIndexMavenTests == otherPtr->m_shouldIndexMavenTests);
|
||||
}
|
||||
|
||||
@@ -49,11 +66,14 @@ void SourceGroupSettingsWithJavaMaven::load(const ConfigManager* config, const s
|
||||
{
|
||||
setMavenProjectFilePath(
|
||||
config->getValueOrDefault(key + "/maven/project_file_path", FilePath(L"")));
|
||||
setMavenSettingsFilePath(
|
||||
config->getValueOrDefault(key + "/maven/settings_file_path", FilePath(L"")));
|
||||
setShouldIndexMavenTests(config->getValueOrDefault(key + "/maven/should_index_tests", false));
|
||||
}
|
||||
|
||||
void SourceGroupSettingsWithJavaMaven::save(ConfigManager* config, const std::string& key)
|
||||
{
|
||||
config->setValue(key + "/maven/project_file_path", getMavenProjectFilePath().wstr());
|
||||
config->setValue(key + "/maven/settings_file_path", getMavenSettingsFilePath().wstr());
|
||||
config->setValue(key + "/maven/should_index_tests", getShouldIndexMavenTests());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user