diff options
author | Simon Brandhof <simon.brandhof@gmail.com> | 2012-02-21 10:11:34 +0100 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@gmail.com> | 2012-02-21 10:11:34 +0100 |
commit | b27c50696631e0b9d4183a576e7c9783d5084ad7 (patch) | |
tree | f9757f06c49918fc718a020b2fc2ba3b7387a05b | |
parent | adf17bb64788433913ddd97f92b08141035a4586 (diff) | |
download | sonarqube-b27c50696631e0b9d4183a576e7c9783d5084ad7.tar.gz sonarqube-b27c50696631e0b9d4183a576e7c9783d5084ad7.zip |
Minor change in ChartFactory
-rw-r--r-- | sonar-server/src/main/java/org/sonar/server/charts/ChartFactory.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/sonar-server/src/main/java/org/sonar/server/charts/ChartFactory.java b/sonar-server/src/main/java/org/sonar/server/charts/ChartFactory.java index 7515a44fae5..4730a8210c3 100644 --- a/sonar-server/src/main/java/org/sonar/server/charts/ChartFactory.java +++ b/sonar-server/src/main/java/org/sonar/server/charts/ChartFactory.java @@ -19,6 +19,7 @@ */ package org.sonar.server.charts; +import com.google.common.collect.Maps; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.sonar.api.ServerComponent; @@ -27,9 +28,10 @@ import org.sonar.api.charts.Chart; import java.util.HashMap; import java.util.Map; -public class ChartFactory implements ServerComponent { +public final class ChartFactory implements ServerComponent { private static final Logger LOG = LoggerFactory.getLogger(ChartFactory.class); - private Map<String, Chart> chartsByKey = new HashMap<String, Chart>(); + private Map<String, Chart> chartsByKey = Maps.newHashMap(); + public ChartFactory(Chart[] charts) { for (Chart chart : charts) { |