@Test public void getMetrics() { Map<String, String > metrics = new HashMap<>(); metrics.put("Key 1", "Val 1"); metrics.put("Key 2", "Val 2"); metrics.put("Key 3", "Val 3"); SensitivityAnalysisResult results = new SensitivityAnalysisResult(true, metrics, "", Collections.emptyList(), Collections.emptyMap()); assertEquals(metrics.size(), results.getMetrics().size()); assertEquals("Val 1", results.getMetrics().get("Key 1")); assertEquals("Val 2", results.getMetrics().get("Key 2")); assertEquals("Val 3", results.getMetrics().get("Key 3")); }
public Map<String, String> getMetrics() { return metrics; }
SensitivityAnalysisResult { public Map<String, String> getMetrics() { return metrics; } }
SensitivityAnalysisResult { public Map<String, String> getMetrics() { return metrics; } @JsonCreator  SensitivityAnalysisResult(@JsonProperty("ok") boolean ok,
                                     @JsonProperty("metrics") Map<String, String> metrics,
                                     @JsonProperty("logs") String logs,
                                     @JsonProperty("values") List<SensitivityValue> sensitivityValues,
                                     @JsonProperty("contingenciesValues") Map<String, List<SensitivityValue>> sensitivityValuesContingencies);  SensitivityAnalysisResult(boolean ok,
                                     Map<String, String> metrics,
                                     String logs,
                                     List<SensitivityValue> sensitivityValues); }
SensitivityAnalysisResult { public Map<String, String> getMetrics() { return metrics; } @JsonCreator  SensitivityAnalysisResult(@JsonProperty("ok") boolean ok,
                                     @JsonProperty("metrics") Map<String, String> metrics,
                                     @JsonProperty("logs") String logs,
                                     @JsonProperty("values") List<SensitivityValue> sensitivityValues,
                                     @JsonProperty("contingenciesValues") Map<String, List<SensitivityValue>> sensitivityValuesContingencies);  SensitivityAnalysisResult(boolean ok,
                                     Map<String, String> metrics,
                                     String logs,
                                     List<SensitivityValue> sensitivityValues); boolean isOk(); Map<String, String> getMetrics(); String getLogs(); Collection<SensitivityValue> getSensitivityValues(); Collection<SensitivityValue> getSensitivityValuesByFunction(SensitivityFunction function); Collection<SensitivityValue> getSensitivityValuesByVariable(SensitivityVariable variable); SensitivityValue getSensitivityValue(SensitivityFunction function, SensitivityVariable variable); SensitivityValue getSensitivityValue(SensitivityFactor factor); boolean contingenciesArePresent(); Map<String, List<SensitivityValue>> getSensitivityValuesContingencies(); Collection<SensitivityValue> getSensitivityValuesByFunction(SensitivityFunction function, String contingencyId); Collection<SensitivityValue> getSensitivityValuesByVariable(SensitivityVariable variable, String contingencyId); SensitivityValue getSensitivityValue(SensitivityFunction function, SensitivityVariable variable, String contingencyId); SensitivityValue getSensitivityValue(SensitivityFactor factor, String contingencyId); static SensitivityAnalysisResult empty(); }
SensitivityAnalysisResult { public Map<String, String> getMetrics() { return metrics; } @JsonCreator  SensitivityAnalysisResult(@JsonProperty("ok") boolean ok,
                                     @JsonProperty("metrics") Map<String, String> metrics,
                                     @JsonProperty("logs") String logs,
                                     @JsonProperty("values") List<SensitivityValue> sensitivityValues,
                                     @JsonProperty("contingenciesValues") Map<String, List<SensitivityValue>> sensitivityValuesContingencies);  SensitivityAnalysisResult(boolean ok,
                                     Map<String, String> metrics,
                                     String logs,
                                     List<SensitivityValue> sensitivityValues); boolean isOk(); Map<String, String> getMetrics(); String getLogs(); Collection<SensitivityValue> getSensitivityValues(); Collection<SensitivityValue> getSensitivityValuesByFunction(SensitivityFunction function); Collection<SensitivityValue> getSensitivityValuesByVariable(SensitivityVariable variable); SensitivityValue getSensitivityValue(SensitivityFunction function, SensitivityVariable variable); SensitivityValue getSensitivityValue(SensitivityFactor factor); boolean contingenciesArePresent(); Map<String, List<SensitivityValue>> getSensitivityValuesContingencies(); Collection<SensitivityValue> getSensitivityValuesByFunction(SensitivityFunction function, String contingencyId); Collection<SensitivityValue> getSensitivityValuesByVariable(SensitivityVariable variable, String contingencyId); SensitivityValue getSensitivityValue(SensitivityFunction function, SensitivityVariable variable, String contingencyId); SensitivityValue getSensitivityValue(SensitivityFactor factor, String contingencyId); static SensitivityAnalysisResult empty();  }