fixed sonar bugs
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package de.muehlencord.shared.configuration;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
*
|
||||
* @param <T> the type of the parameter
|
||||
@@ -78,4 +80,11 @@ public interface Configuration<T, V extends T> {
|
||||
* @throws ConfigurationException if the configuration is invalid
|
||||
*/
|
||||
public void validateConfiguration() throws ConfigurationException;
|
||||
|
||||
/**
|
||||
* returns the map of parameters and values
|
||||
*
|
||||
* @return the map of parameters and values
|
||||
*/
|
||||
public Map<Parameter<T>, V> getParameterMap();
|
||||
}
|
||||
|
||||
@@ -16,9 +16,9 @@ public class DefaultConfiguration<T, V extends T> implements Configuration<T, V>
|
||||
/**
|
||||
* the parameter map
|
||||
*/
|
||||
private Map<Parameter<T>, V> parameterMap;
|
||||
private final Map<Parameter<T>, V> parameterMap;
|
||||
/** mapping from name to parameter */
|
||||
private Map<String, Parameter<T>> parameterNameMap;
|
||||
private final Map<String, Parameter<T>> parameterNameMap;
|
||||
|
||||
/**
|
||||
* creates a new instance of a configuration
|
||||
@@ -33,7 +33,7 @@ public class DefaultConfiguration<T, V extends T> implements Configuration<T, V>
|
||||
*
|
||||
* @return the map of parameters and values
|
||||
*/
|
||||
protected Map<Parameter<T>, V> getParameterMap() {
|
||||
public Map<Parameter<T>, V> getParameterMap() {
|
||||
return parameterMap;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user