@Test public void testFindConfiguration_String() { DesaConfiguration ds1 = desaServices.findConfiguration("ds1"); assertNotNull(ds1); assertEquals("ds1", ds1.getServiceId()); assertEquals(Arrays.asList("model:id1", "model:id2"), ds1.getExportModels()); assertEquals(Arrays.asList("acr1", "acr2"), ds1.getNomenclatureAcronyms()); assertEquals("ds1user", ds1.getUsername()); assertEquals("ds1passwd", ds1.getPassword()); assertEquals("https: assertEquals("https: assertEquals("ds1producer", ds1.getProducer()); assertEquals("ds1operator", ds1.getOperator()); }
public DesaConfiguration findConfiguration(MetaModel model) { if (model == null) { return null; } for (String sid : config.getStringArray(PROPERTY_DESASERVICES)) { DesaConfiguration dc = readConfiguration(config, sid); if (dc.getExportModels().contains(model.getPid())) { return dc; } } return null; }
DesaServices { public DesaConfiguration findConfiguration(MetaModel model) { if (model == null) { return null; } for (String sid : config.getStringArray(PROPERTY_DESASERVICES)) { DesaConfiguration dc = readConfiguration(config, sid); if (dc.getExportModels().contains(model.getPid())) { return dc; } } return null; } }
DesaServices { public DesaConfiguration findConfiguration(MetaModel model) { if (model == null) { return null; } for (String sid : config.getStringArray(PROPERTY_DESASERVICES)) { DesaConfiguration dc = readConfiguration(config, sid); if (dc.getExportModels().contains(model.getPid())) { return dc; } } return null; } DesaServices(Configuration config); }
DesaServices { public DesaConfiguration findConfiguration(MetaModel model) { if (model == null) { return null; } for (String sid : config.getStringArray(PROPERTY_DESASERVICES)) { DesaConfiguration dc = readConfiguration(config, sid); if (dc.getExportModels().contains(model.getPid())) { return dc; } } return null; } DesaServices(Configuration config); List<ValueMap> getValueMap(Nomenclatures n, String pluginId); Nomenclatures getNomenclatures(DesaConfiguration dc, UserProfile user); DesaClient getDesaClient(DesaConfiguration dc); String getOperatorName(UserProfile operator, DesaConfiguration dc); String getProducerCode(UserProfile operator, DesaConfiguration dc); DesaConfiguration findConfiguration(MetaModel model); DesaConfiguration findConfiguration(String serviceId); DesaConfiguration findConfigurationWithModel(String... modelIds); List<DesaConfiguration> getConfigurations(); }
DesaServices { public DesaConfiguration findConfiguration(MetaModel model) { if (model == null) { return null; } for (String sid : config.getStringArray(PROPERTY_DESASERVICES)) { DesaConfiguration dc = readConfiguration(config, sid); if (dc.getExportModels().contains(model.getPid())) { return dc; } } return null; } DesaServices(Configuration config); List<ValueMap> getValueMap(Nomenclatures n, String pluginId); Nomenclatures getNomenclatures(DesaConfiguration dc, UserProfile user); DesaClient getDesaClient(DesaConfiguration dc); String getOperatorName(UserProfile operator, DesaConfiguration dc); String getProducerCode(UserProfile operator, DesaConfiguration dc); DesaConfiguration findConfiguration(MetaModel model); DesaConfiguration findConfiguration(String serviceId); DesaConfiguration findConfigurationWithModel(String... modelIds); List<DesaConfiguration> getConfigurations(); static final String PROPERTY_DESASERVICES; static final String PREFIX_DESA; static final String REMOTE_USER_TYPE; }