MonitorBuilder extends AbstractBuilder<MonitorConfig, MonitorBuilder> { public MonitorBuilder appendParameter(String key, String value) { this.parameters = appendParameter(parameters, key, value); return getThis(); }  MonitorBuilder protocol(String protocol); MonitorBuilder address(String address); MonitorBuilder username(String username); MonitorBuilder password(String password); MonitorBuilder group(String group); MonitorBuilder version(String version); MonitorBuilder interval(String interval); MonitorBuilder isDefault(Boolean isDefault); MonitorBuilder appendParameter(String key, String value); MonitorBuilder appendParameters(Map<String, String> appendParameters); MonitorConfig build();  }
@Test void appendParameter() { MonitorBuilder builder = new MonitorBuilder(); builder.appendParameter("default.num", "one").appendParameter("num", "ONE"); Map<String, String> parameters = builder.build().getParameters(); Assertions.assertTrue(parameters.containsKey("default.num")); Assertions.assertEquals("ONE", parameters.get("num")); }