@Test public void importData() { Network network = Importers.importData(loader, TEST_FORMAT, null, null, computationManager, importConfigMock); assertNotNull(network); assertNotNull(network.getLoad("LOAD")); }
public static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config) { Importer importer = getImporter(loader, format, computationManager, config); if (importer == null) { throw new PowsyblException("Import format " + format + " not supported"); } return importer.importData(dataSource, parameters); }
Importers { public static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config) { Importer importer = getImporter(loader, format, computationManager, config); if (importer == null) { throw new PowsyblException("Import format " + format + " not supported"); } return importer.importData(dataSource, parameters); } }
Importers { public static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config) { Importer importer = getImporter(loader, format, computationManager, config); if (importer == null) { throw new PowsyblException("Import format " + format + " not supported"); } return importer.importData(dataSource, parameters); } private  Importers(); }
Importers { public static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config) { Importer importer = getImporter(loader, format, computationManager, config); if (importer == null) { throw new PowsyblException("Import format " + format + " not supported"); } return importer.importData(dataSource, parameters); } private  Importers(); static Collection<String> getFormats(ImportersLoader loader); static Collection<String> getFormats(); static Collection<Importer> list(ImportersLoader loader, ComputationManager computationManager, ImportConfig config); static Collection<Importer> list(ComputationManager computationManager, ImportConfig config); static Collection<Importer> list(); static Importer getImporter(ImportersLoader loader, String format, @Nullable ComputationManager computationManager, ImportConfig config); static Importer getImporter(String format, @Nullable ComputationManager computationManager, ImportConfig config); static Importer getImporter(String format, @Nullable ComputationManager computationManager); static Importer getImporter(String format); static Collection<String> getPostProcessorNames(ImportersLoader loader); static Collection<String> getPostProcessorNames(); static Importer addPostProcessors(ImportersLoader loader, Importer importer, ComputationManager computationManager, String... names); static Importer addPostProcessors(Importer importer, ComputationManager computationManager, String... names); static Importer addPostProcessors(Importer importer, String... names); static Importer setPostProcessors(ImportersLoader loader, Importer importer, ComputationManager computationManager, String... names); static Importer setPostProcessors(Importer importer, ComputationManager computationManager, String... names); static Importer setPostProcessors(Importer importer, String... names); static Importer removePostProcessors(Importer importer); static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config); static Network importData(String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager); static Network importData(String format, ReadOnlyDataSource dataSource, Properties parameters); static Network importData(String format, String directory, String baseName, Properties parameters); static void importAll(Path dir, Importer importer, boolean parallel, Properties parameters, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void importAll(Path dir, Importer importer, boolean parallel, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void importAll(Path dir, Importer importer, boolean parallel, Consumer<Network> consumer); @Deprecated static Object readParameter(String format, Properties parameters, Parameter configuredParameter); @Deprecated static Object readParameter(String format, Properties parameters, Parameter configuredParameter, ParameterDefaultValueConfig defaultValueConfig); static DataSource createDataSource(Path file); static DataSource createDataSource(Path directory, String fileNameOrBaseName); static Importer findImporter(ReadOnlyDataSource dataSource, ImportersLoader loader, ComputationManager computationManager, ImportConfig config); static Importer findImporter(ReadOnlyDataSource dataSource, ComputationManager computationManager); static Network loadNetwork(Path file, ComputationManager computationManager, ImportConfig config, Properties parameters, ImportersLoader loader); static Network loadNetwork(Path file, ComputationManager computationManager, ImportConfig config, Properties parameters); static Network loadNetwork(Path file); static Network loadNetwork(String file); static Network loadNetwork(String filename, InputStream data, ComputationManager computationManager, ImportConfig config, Properties parameters, ImportersLoader loader); static Network loadNetwork(String filename, InputStream data, ComputationManager computationManager, ImportConfig config, Properties parameters); static Network loadNetwork(String filename, InputStream data, ComputationManager computationManager); static Network loadNetwork(String filename, InputStream data); static void loadNetworks(Path dir, boolean parallel, ImportersLoader loader, ComputationManager computationManager, ImportConfig config, Properties parameters, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ImportersLoader loader, ComputationManager computationManager, ImportConfig config, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ComputationManager computationManager, ImportConfig config, Properties parameters, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ComputationManager computationManager, ImportConfig config, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ComputationManager computationManager, ImportConfig config, Consumer<Network> consumer); static void loadNetworks(Path dir, boolean parallel, Consumer<Network> consumer); static void loadNetworks(Path dir, boolean parallel, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, Consumer<Network> consumer); }
Importers { public static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config) { Importer importer = getImporter(loader, format, computationManager, config); if (importer == null) { throw new PowsyblException("Import format " + format + " not supported"); } return importer.importData(dataSource, parameters); } private  Importers(); static Collection<String> getFormats(ImportersLoader loader); static Collection<String> getFormats(); static Collection<Importer> list(ImportersLoader loader, ComputationManager computationManager, ImportConfig config); static Collection<Importer> list(ComputationManager computationManager, ImportConfig config); static Collection<Importer> list(); static Importer getImporter(ImportersLoader loader, String format, @Nullable ComputationManager computationManager, ImportConfig config); static Importer getImporter(String format, @Nullable ComputationManager computationManager, ImportConfig config); static Importer getImporter(String format, @Nullable ComputationManager computationManager); static Importer getImporter(String format); static Collection<String> getPostProcessorNames(ImportersLoader loader); static Collection<String> getPostProcessorNames(); static Importer addPostProcessors(ImportersLoader loader, Importer importer, ComputationManager computationManager, String... names); static Importer addPostProcessors(Importer importer, ComputationManager computationManager, String... names); static Importer addPostProcessors(Importer importer, String... names); static Importer setPostProcessors(ImportersLoader loader, Importer importer, ComputationManager computationManager, String... names); static Importer setPostProcessors(Importer importer, ComputationManager computationManager, String... names); static Importer setPostProcessors(Importer importer, String... names); static Importer removePostProcessors(Importer importer); static Network importData(ImportersLoader loader, String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager, ImportConfig config); static Network importData(String format, ReadOnlyDataSource dataSource, Properties parameters, ComputationManager computationManager); static Network importData(String format, ReadOnlyDataSource dataSource, Properties parameters); static Network importData(String format, String directory, String baseName, Properties parameters); static void importAll(Path dir, Importer importer, boolean parallel, Properties parameters, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void importAll(Path dir, Importer importer, boolean parallel, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void importAll(Path dir, Importer importer, boolean parallel, Consumer<Network> consumer); @Deprecated static Object readParameter(String format, Properties parameters, Parameter configuredParameter); @Deprecated static Object readParameter(String format, Properties parameters, Parameter configuredParameter, ParameterDefaultValueConfig defaultValueConfig); static DataSource createDataSource(Path file); static DataSource createDataSource(Path directory, String fileNameOrBaseName); static Importer findImporter(ReadOnlyDataSource dataSource, ImportersLoader loader, ComputationManager computationManager, ImportConfig config); static Importer findImporter(ReadOnlyDataSource dataSource, ComputationManager computationManager); static Network loadNetwork(Path file, ComputationManager computationManager, ImportConfig config, Properties parameters, ImportersLoader loader); static Network loadNetwork(Path file, ComputationManager computationManager, ImportConfig config, Properties parameters); static Network loadNetwork(Path file); static Network loadNetwork(String file); static Network loadNetwork(String filename, InputStream data, ComputationManager computationManager, ImportConfig config, Properties parameters, ImportersLoader loader); static Network loadNetwork(String filename, InputStream data, ComputationManager computationManager, ImportConfig config, Properties parameters); static Network loadNetwork(String filename, InputStream data, ComputationManager computationManager); static Network loadNetwork(String filename, InputStream data); static void loadNetworks(Path dir, boolean parallel, ImportersLoader loader, ComputationManager computationManager, ImportConfig config, Properties parameters, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ImportersLoader loader, ComputationManager computationManager, ImportConfig config, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ComputationManager computationManager, ImportConfig config, Properties parameters, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ComputationManager computationManager, ImportConfig config, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, boolean parallel, ComputationManager computationManager, ImportConfig config, Consumer<Network> consumer); static void loadNetworks(Path dir, boolean parallel, Consumer<Network> consumer); static void loadNetworks(Path dir, boolean parallel, Consumer<Network> consumer, Consumer<ReadOnlyDataSource> listener); static void loadNetworks(Path dir, Consumer<Network> consumer);  }